How to prevent iPhone from being turned off? (security intention)
No software prevents powering off many iPhone. 


physical control over the power buttons means you can power down all Apple products.
Putting it in lost mode via iCloud is still your best move to hope to recover a device that you suspect or know is stolen. 
Filing a police report and contacting your mobile carrier are good as well.


Opting in to Offline Finding is one new development Apple has to combat the scenario you mention.



This does use Bluetooth, which works when power is on. However, this makes it more likely the device might get located when powered on and in range of cellular, known WiFi, or just Bluetooth on.