Why do light fixtures, dimmer switches, etc. use stranded wire?
That's only a problem if your wire-nut technique is bad.
Most people's technique is terrible when they start.  Where people depart is that some refuse to learn, and do not test their work, or think, or refine their technique. They simply tape the wires onto the nuts to keep them from falling apart.  This only hides the symptom; the root problem is a poor electrical connection, which results in overheating, arcing, and a meltdown or fire.
Just don't be that person and you'll be fine.