Earpods volume control and mic don't work while plugged in
I have a problem with controlling volume and using Earpods mic with my iPhone SE (stereo playback and play/pause button are working correctly). They are original set and work fine (tested with macbook - volume control and mic are OK). Also already tested two different pairs of Earpods with the iPhone and they both don't work. Also tested the lightning Earbuds and they are working fine. That means something is wrong with the iPhone itself, probably the jack connector. Thought it might be dirt or something inside the connector but it doesn't look like there's anything inside. It may be a software issue (11.2.6) but don't know how to determine is it hardware or software and how to address the issue.
What else can I try to do to fix it?
I'd be very grateful for any help.
Is this a good question?