I've tried everything I could think of in order to solve this. I've signed out of my account in "music" on Mac, signed completely out of iCloud on my phone, restored my phone, tried syncing via wifi as opposed to a cable. When you plug your phone in and it shows up in Music, it will show you all the music on it. You can add a "last played" option to see what was last played on your phone and nothing I play on my phone shows up as played even before I sync it. So I'm kind of at a loss here. Meanwhile I was using iTunes on Windows previously and had absolutely no problem.
I don’t think I can help much, but I know that play counts are super-fickle and confusing. I have iTunes Match and Big Sur and rely on wireless to sync everything. I think play counts update only once a day for me in my Music app on my MacBook Air (unless I play them directly on the MacBook Air, I’m which case they update in real time). And they only update for songs I played yesterday in addition to the first track I played today. And they only seem to update songs played yesterday on the device that first plays today’s first song.
So...I think that if you play a song on your iPhone, it should update the play count for that song (but not the songs after that first song) in addition to the backlog of other songs you played on your iPhone yesterday and earlier. However, that one song for today on your iPhone has to be the first song you’ve played today on any of your devices.
However, that “technique” didn’t work for me after a road trip on which I’d used my iPhone with wired CarPlay. I got home, played a song on my iPhone as the first song I’d played all day on any of my devices, thinking it would trigger an update. But all the songs I’d played on the iPhone-thru-CarPlay for a week went without a play count update for several days. Then suddenly I noticed that they had updated. I’m not sure how or why.
So, maybe yours will update after a few days, like mine did? If not, maybe try playing songs exclusively on your iPhone for a couple days? If you’ve already been doing that, or if it still doesn’t work...I admit that I’m out of ideas. I’ve been trying to figure out play counts for years, and I’m pretty sure I still don’t understand them.