Hello Christian,
it seems the problem were Windows junctions. Like in:
import module namespace [...] at "file:///C:/Users/andreas/Eigene%20Projekte/XQuery/text-lib/src/regex-lib.xqm"; import module namespace [...] at "file:///S:/Users/andreas/Eigene%20Projekte/XQuery/text-lib/src/regex-lib.xqm";
I have two volumes: an SSD and a magnetic disk. The magnetic stores many such folders, that consume a lot of space, like my home folder. I have a Windows junction https://en.wikipedia.org/wiki/NTFS_junction_point from 'C:\Users\andreas\Eigene%20Projekte' to 'S:\Users\andreas\Eigene%20Projekte'. After I set all links to point to the same volume (the real, physical directory), it seems to be alright now.
Happy egg laying bunnies!