It's because proper mountain bikers break stuff, mostly in the middle of nowhere, where their significant others can't find them. On the other hand, roadies are on Google maps...
This. A road bike is a very simple machine compared to a dual suspension mountain bike. MTBs require a lot more maintenance (or they just degrade faster). Try actually sticking to the rock shox service interval for example and you will go broke on servicing alone. The problem in for MTB if you don't maintain your own stuff then you are either compromising the experience or you are paying someone a fair bit to do it. Road bikes generally don't get grime and you can run them on a much longer service interval without too many problems. Similarly cross folk are probably on par, or better, than MTB folks wrt maintenance and knowing how stuff works. Their bikes cop a beating during race season.
The other aspect is road bikes are simple things roadies tend to do really shitty upgrades that do 1/1000ths of sweet FA. Swapping stems, going saddle hunting, losing 20 grams here and there, then maybe different bar tape. All superficial stuff that doesn't change the ride and so most stuff stays stock and all that really happens is a frequent lube, pump the tyres and then consumables once in a while that the shop does. Initially there might be some fitting, but a shop does that and roades tend to love going nuts of bike fits. On a MTB you have a tonne of dialing the bike in and to do that you have to know how it works. Pre-shockwiz, you had to ride, tune and then repeat over and over. There is shocks pressure and rebound, tyre choice, pressure etc. Then wider bars, brake types an droppers.
So in summary naturally a discipline that is both more prone to breakage, higher maintenance and is more responsive to modifications and changes means the folks tend to be more mechanically competent by necessity.