Hi MN1509,
Thanks for replying and sharing the additional information.
Let's take a look at what's happening with your iMac, as that can affect how apps respond. When your Mac will not shut down as expected, holding down the power button is the correct next step, which you shouldn't need to do every time. We'll want to try and isolate this issue to either the macOS or the user profile.
First, start up your iMac in safe mode, by following the steps here: Use safe mode to isolate issues with your Mac. Keep in mind that the display may flicker and not look as it usually does, which is normal for safe mode. Once booted up, see if you're able to shut down normally.
If so, then you'll want to restart normally and try to shut down again. Safe mode does run some system checks and may actually resolve some issues.
If you're still not able to shut down normally in safe mode, we'll next want to create a test user. Here are the steps to do so: How to test an issue in another user account on your Mac. While logged in to the test user, try to shut down again and see if you're able to.
You're welcome to reply back with your findings and we'll then recommend the next steps.
Enjoy your day!