There are at least two effects at work here, as follows.
Because the gauge blocks are optically flat (very flat indeed) it is possible to squeeze them together hard enough to form a few metallic bonds between the blocks. The other effect is that once they have been squeezed together hard enough to press out the air trapped between them, air must be re-admitted into the space between them in order to pull them apart once again- and the finite viscosity of the air makes this hard to do.
Note that the "vacuum weld" phenomenon was discovered when satellites were first shot into orbit and it was discovered that their antennae, solar cell wings, etc. failed to unfurl upon command. Tests on the ground revealed that in a vacuum, the metal-to-metal contact in the unfurling mechanisms caused them to jam and get stuck.
BTW this problem could not be cured through the use of silicone-based "vacuum grease" because those silicone-based lubricants showed a marked tendency to diffuse out across surfaces in a vacuum, which then fouled the sensors and lenses on the satellites.