My suggestion would be to not do it based in geometry. Use prefabs instead of just models and include snap-points in them - up to you how to do this, but I would suggest either categorical ones - window here, door here, floor/wall/door here, or size based ones. The snap points can just be other nodes in the prefab, and just copy the world position and rotation from them when adding a new node. Another suggestion is looking into how snapping weapons to hands and such is usually done.
Alternatively, it you have only regularly sized components (like Minecraft), you can define a grid system whenever you add a component, unless it meets some criteria to add it to the grid of a previous one.
If you're just looking into how to do it statically (not as part of the game), I would look into how to do it in Blender, etc. and then just import the scene.