Aches and pains tend to come and go, so it's hard to know if a particular exercise is the one that solved a specific pain.
However, I've been doing a shoulder blade squeeze a lot recently, and the pain that I've had right where the neck and shoulder meet, has gone away. Recently, I've been really squeezing hard during this exercise, and I think that made the difference. IOW, it's not a stretch, it's more like an isotonic strength-training thing. It sounds like it builds up the muscles so that there's more room, and less rubbing.
The exercise described at 1:42 in the video below, although the issue described is different from what I have. You can do it while riding.
I figured I should share this in case someone else is having exactly the issue I've had.