It's important that the door covers the doorway so that the door cannot fall out of the frame.
In the first picture you can see a frame with a piece of wood of the same size like the doors I made out of 2mm wood and 2 profiles which are each 1mm thick...so the doors are 4mm thick and have 1mm space between the wall and the frame because the frame's staffs are 5mm thick...That's how I made it in the past, but, indeed there are better ways to do the doorframes...
The second picture shows a door from outside the building C...