While Android phones don’t have a mute button, Apple does switch on the sideAlthough phone models evolve, they never remove it.
When you want to mute or unmute just like any other phone although you can do this from the screen Why do iPhones have an extra button?
First we have to get to the iPod times.

Released in 2001, the iPod is similar to today’s iPhones, but then serves a different purpose It had a button on it.
iPods, generally used for listening to music, were often carried in pockets or bags. The button on the side allows users to control their iPod. when they want to put it in their pockets or bags it allowed to disable other keys.
When the first iPhone was released in 2007, iPods had the same button.

The switch on the side was there for a different purpose than on the iPod. Since the phone already has a lock screen, this is key to mute the phone without turning it on decided to use.
The switch offers convenience, especially for environments where removing the phone would not be welcome.

To turn off the sound on Android phones, you need to open a bright screen and tap the screen a few times. On iPhones, your phone without having to take it out of your pocket you can do this easily. Thus, your work becomes much easier, especially in places such as cinemas or meetings.
This feature changes with the iPhone 15.

The newly released iPhone 15 does not move the key key like a notch, to use by pressing had been designed. In addition, the user determines for which operation this key is used.
In brief; low power mode, screenshot, Shazam, flashlight etc. Press this button you want from the options. can name.
Sources: Apple Explained, Medium