You are correct and as others have said, the phone can run functions while it looks like its off. This was one of the main reasons manufacturers killed removable batteries. You can put your phone onto standby, but you cannot power it off completely.

There are also conspiracy theories that claim the last 10% of battery is reserved for tracking, so that when your phone says its out of battery and wont turn on, it still has plenty of power left to ping tracking data say once per hour or something. I dont push those theories, but judging by what Snowden released all those years ago I wouldnt be surprised.