The square hole is for a pulley block that routes the shift cable on Bromptons with internally-geared hubs. Looks like you have a two-speed, and do not have this pulley block.
Hmmmm, chrome Brompton. Must get on with my restoration project on my rat Brompton. Just as soon as I've finished the P2 rebuild, the P5 build, @Cycliste's new TT bike and I've finished rebuilding my Cannondale. Then I'll get right on with it.
What does this do?
I cannot see that it acts/integrates with any part of the bike.
Folded or otherwise.
*Mystified