Why does my iPhone turn on when I plug it in to charge?
Apple designed the hardware to power on when it detects charging power.
When the operating system is off, the hardware still remains sensitive to the introduction of charging power. Not only does this help in cases where the OS has frozen and run down the battery past the point where available voltage can even run the system (including the charging circuitry) but it also helps in the more common case of &quot;my phone is dead&quot; and I'd like it back without having to press buttons. Depending on how long the battery self-discharged after crossing the &quot;empty&quot; line, it may need tens of seconds or even minutes of charging to get back to the minimum viable voltage. At that point, the sleep/wake button can become effective again for starting the OS.

You can of course plug in the power and then shut off the operating system phone to Charge with the OS halted. The charging circuitry runs whether the OS is running or not, and that circuitry is what kicks the OS to start when the 30 pin, lightning, USB-C or wireless charging commences while the OS is not running.