This is because the phone’s function of automatically playing music when headphones are plugged in is turned on.
Take the Xiaomi 6 mobile phone as an example. The method to turn off this function is as follows:
1. First open the Xiaomi 6 mobile phone, and then find the "Settings" item on the desktop of the Xiaomi Mi 6 mobile phone. icon and click to enter.
2. After entering the settings interface of Xiaomi 6 mobile phone, select the "Headphone Line Control" option.
3. After entering the headset wire control, find the "Auto-play when plugged in" item and turn it off.