I don't know if there is a full tutorial for making doors and windows but I would suggest exporting an EA mesh and looking how the mesh is build. There are a few mesh groups for the frame, glass, the wall around it etc. The meshes are split into the pieces that show up on the exterior and the interior side. So for example a window has 7 different mesh groups.
Here is an example looking at the large modern glass window from base game:
s4studio_mesh__0 = wall back (or more precisely the shadow on the wall surrounding the window)
s4studio_mesh__1 = wall front (or more precisely the shadow on the wall surrounding the window)
s4studio_mesh__2 = inner frame (the piece between the front and back frame that connects both parts)
s4studio_mesh__3 = frame front
s4studio_mesh__4 = glass front
s4studio_mesh__5 = glass back
s4studio_mesh__6 = frame back
Depending on which mesh you use as a base mesh groups may be assigned differently.
For size reference while meshing I suggest exporting the mesh of an in game window of the size you want to make as a reference.
Every door/ window/ arch has a Cutout info table and a matching cutout mask image that defines the wall height and the size of the cutout of the wall in game.
There is also a great tutorial for making your own wall cutout masks
here.
The last thing I want to mention is that you may adjust the postion of the rig in sims 4 studio.
For example:
_bind_doorSwing_ defines the way your door opens up
_ctnm_curtain_INT/EXT is important for the slots where curtains snap to