For a long time I had been perplexed by this, and even when people would give explanations things just felt off about their explanations.
Here's what I found was helpful for my own personal understanding. It's a little bit round-a-bout but I think it really helps.
If I put a ball in space and throw it it goes straight:
If I tie it to a mass that's much heavier than it, it'll instead spin in a circle around it.
And the same idea will happen if I connect two rocks of the same mass, and I give one end a push:
This, to me, is THE secret for rolling. If two masses are stuck together, when you push one (in the direction in the image) the second mass is pushed in the opposite direction. Just one tug gets it to rotate forever.
Now we can easily turn this into our "wheel" by just adding more mass. I believe you're going to assume the system will have these special rotation properties if I add more blocks on opposite sides:
Now in fact the only thing that matters, as we've said, is that everything is the same mass and equal distances apart. Well I can in fact just connect all of the masses together, and then they'll be locked in place, forced to have the same behavior. If I do that, then I can end up with something that looks like this:
The key in getting a good intuition is thinking of your wheel as a bunch of rocks glued together. In this case, just by giving a single one of our "rocks" a push, we can get the entire thing to spin forever. We call this a fancy name "angular momentum," and I think often don't explain that it's just what happens to when things are "glued together," like in this example.
When something obstructs one end of this spinning mass, the rest of still wants to move! So if your spinning mass hits a bump, it will pivot at that stopping point:
In the wheel case, little tiny changes in the shape of the ground are pushing against the masses that are stuck together, and as a result the top half moves while the bottom half doesnt. The advantage here over the previous case is that these little tiny bumps can be made so small that our wheel grips the ground like a gear and uses it to push off of. The losses due to friction with the gear are very small, relative to just pushing a flat rock on the ground (which has the entire surface area of the rock-to-ground contact locked like a gear, shown in Alexander's answer.) In the end, the key is that our masses being locked together allow us to turn linear inertia into "eternal spinning," if we have a very very flat contact with the ground (but some "interlocking" so we can push off of it), then we can efficiently turn this "eternal spinning" back into linear motion more efficiently!
Personally I think the wheel is around us so much it's hard to take a step back and wonder "what's so great about rolling?" But the reality is that it is a pretty "unnatural" and unintuitive thing, at least according to nature. It's easier to evolve legs than it is to evolve wheels. You need very particular conditions to get this effect to work, and I don't think just writing down some friction terms or L = r x p does one of mankind's greatest inventions any justice!