It feels like because all of the data about a problem is being unloaded into long term memory, when you return to the problem, you parse the entire data as once instead of adding to it in pieces.
It almost feels like a puzzle except the second time looking at it, you're looking at the whole thing you've solved versus just the piece you last added.
https://www.scientificamerican.com/article/why-walking-throu...
It would be an interesting experiment to think on a problem, then swap to a different office and see if that gives you a different perspective and insight.
I really liked Rich Hickeys talk on Hammock Driven Development which is basically this exact subject: load everything into your brain and then go snooze on a hammock while your mind gets to work.
If you simply sat in a chair and starred at a wall, you don't have the same effect as being in the shower, toilet, car, on a walk, etc.
Also for many, simply sitting in a room listening to music can do this as well. It's like your brain needs to distract itself from... itself.
Sadly that does not occur so much now that I am driving to work. I wonder if cycling vs sitting is the differentiater here.