I thought I had received a defective Bose QC20 because the volume control had no effect on my iPhone 6 (fully up to date on software with 12.4). I did a cold restart and even updated from 12.3 to 12.4.
Then I had the sense to try the headphones on an iPad mini - worked fine.And then on an iPad - also works fine.
So my earphones seem to be working properly. Any suggestions as to why they work on an iPad, an iPad mini but not an iPhone 6?
If you have a case on the phone remove it and see if it makes any difference. Sometimes the case prevents full insertion of the jack.
Additionally I would also check to see if some pocket lint has accumulated in the headphone socket preventing the jack to insert all the way. While you are at it check the lightning port as well as I recently had some accumulation in mine preventing a good connection. I wouldn't poke anything metal in there but a few, long, stiff bristles from a brush might be enough to dislodge the lint then either try to blow it out or vaccuum it out.