My iPhone 10 locked up hard a few days and I couldn’t get it to turn off using the standard method.
After some digging, I found a new trick that I guess is implemented at a lower level: press and release volume up, then volume volume down, then press and hold the main button until it powers off.
No, on the newer iPhones press and hold simply brings up Siri. Gotta press and hold main button and either volume button simultaneously. If that doesn’t work you should be able to use the trick I describe above.