It's largely just a matter of complexity. DOS was very simple, the OS really didn't do much, there wasn't a bunch of stuff running in the background, it was just the command interpreter. Most of the software back then was fairly simple as well although I did have plenty of DOS programs crash. Modern computers and operating systems are orders of magnitude more complex so there are many, MANY more ways something can go wrong. Even so, ever since Win95 most crashes have been down to bad drivers or hardware faults. Win95 did a pretty good job of isolating programs from each other so it was difficult for a program to take down the whole system.
I've had some PCs that were more stable than others but the ones that were less stable I strongly suspect was due to hardware faults or unlucky combinations of components and drivers.