I have encountered this same problem. I have an iPhone 12, running iOS 17.2.1 on a Windows 11 Pro computer running iTunes 12.13.1.3. I am connected using a USB-C to lightning cable from Apple (relatively new: I think I purchased it last year): everything was fine until about a month ago.
The sync always seems to get stuck at step 3 (preparing to sync, after completing the backup at step 2). It usually happens when I first connect in the morning and start my sync and backup. I have found that if I just disconnect the iPhone, let the sync abort, then immediately reconnect and start the sync anew, the sync and backup complete without problem. I tried aborting the sync within iTunes without disconnecting the cable, but iTunes is still stuck, so the sync doesn't abort that way.
I cannot comment on if the problem might recur later: I typically only perform the sync and backup at the start of the day. I tried forcing MDCrashReportTool to quit, which did let the sync advance, but as others have reported that the sync doesn't always complete using that technique, I don't trust it.