Just a follow-up:
Apparently the solution is as simple as just to do boolean fragments
in gmsh (or pygmsh). This solves the mesh issue at the intersection of two objects. Applying this to all of the objects (after proper boolean addition/subtraction) solved the main issue.
The method to import this mesh into a code can be found here.