Here's a bit of a clue to how it works:
./python
Python 3.11.4 (heads/pypack1:65ac8ac, Oct 16 2023, 02:35:05) [GCC 11.2.0] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import sqlite3
>>> sqlite3
<module 'sqlite3' from '/zip/Lib/sqlite3/__init__.pyc'>
>>> import pathlib
>>> list(pathlib.Path("/zip").glob("*"))
[PosixPath('/zip/.symtab.amd64'), PosixPath('/zip/.symtab.arm64'), PosixPath('/zip/usr'), PosixPath('/zip/.cosmo'), PosixPath('/zip/Lib'), PosixPath('/zip/build')]
From Python's point of view there a "/zip/" folder with stuff in it, presumably stuff that's hidden inside the fat binary.