Print box twice.
Optionally, print also lock. Once as it is and another one mirrored.
Stick locks into grooves in the bottom. Small boxes will be fixed in corner positions but you can still take them out.
Look at Ikea TROFAST box insert (2 levels) if you prefer four lower boxes instead.
There is also community model for the middle gap.
The author marked this model as their own original creation.