You can make your headphone cord longer by attaching a long extension cord to both ends or replacing the older one. You should get a good quality extension cable with your desired length and solder it in the place of the original cable. Or you should get an audio cable extender. These typically have two ends, with one 3.5mm male end and another female end which you can plug into your headphones original cable and make it longer. Though these can make some slightly distorted noise but they’re easy to plug in or remove based on preference.