normally the headphone jack provides a link for headphones with e.g. microphones or buttons (to accept calls), which uses the same wires as for the audio.
the effect can be triggered by e.g. dirty connectors. so I once had a new pair of headphones and on the connector jack there was a bit of debris (glue or whatever left). they did also cause the phone to pause/play every now and then. so I cleaned them and then they did work without problems. also sometimes the connectors have to "grind in" until there is a good electrical connection.
however as it is steadily pausing/playing on your iPhone 5 headphones, I dont think theres an issue with the connection itself.
it might just be that the iPhone 5 headphones are trying to "communicate" with your phone, which it doesnt support and therefore is misinterpreting it as the start/stop commands. you cant do anything about it I guess.
(except dont buy apple products anymore

)