I think I can at least partly explain it as a distraction from whatever anxiety inducing thoughts I might otherwise be running in my head.
If I’m engaged in something, I can’t really think about anything else. My mind stays on a relatively straight track, long enough that my body finally relaxes and I drift off.
But if I’m bored, my mind wanders to more “interesting” things that aren’t exactly soothing, and my mind’s director isn’t nearly as … linear or focused.
I listen to podcasts about topics that fascinate me. I fall sleep within mins and have to relisten during waking hours the next day.
Now, falling asleep with AirPods in every night? Maybe not the best habit. But I know it works when I need it to.