With iOS 11, you can shut down your Apple iPhone or Apple iPad without using the power button
To shut down your iOS device, go to Settings, General, Shut Down and slide the power button to the right
So let's say that for some reason you cannot use any buttons to turn off your Apple iPhone or Apple iPad. For the purposes of this story, assume that the power button (sleep/wake) is not working. As a result, pressing the power button and the home button is also not resetting your device. Since the Apple iPhone 7 doesn't have a mechanical home button, a change was made. To reset the phone, users have to press the power button for 3 seconds, and press volume down while still pressing the power button. But again, we are assuming that this method is not working.
Besides a glitch or a problem causing the buttons to fail, perhaps there is a reason why you can't use physical buttons. Whatever the reason, if you are having trouble turning off your iPhone or iPad with the usual methods, remember that with iOS 11 installed, you can shut down your phone or tablet with the aforementioned four easy steps.
source: AppleInsider
Things that are NOT allowed: