I discovered the similar issue today. I have also iPhone Xs and I was using Apple wired EarPods. Call came in and although I could receive it by pressing center button on headset remote, I could not hear a thing and the other party from me neither. Later I started to investigate. Did all settings reset. After phone reboot connected the headset and called myself from other phone. It worked... until second try. Then I did factory reset and restored phone from iTunes backup. Again, first try worked but second one did not. I did find a pattern: after reset the phone-ringing was loud as usual. As I said first try was successful and all remote buttons and phone buttons (speakerphone, contacts etc) did work, it was possible to change the volume. On later, failed attempt the ringing was much quieter. The remote center button worked, the call was silent. Phone UI became very slow, speakerphone button did react literally seconds after being pressed and has no effect at all. It was not possible to change "call" volume, neither from the headset remote or phone itself. If I did disconnect the headset during that failed call, the phone receiver worked and the microphone too. But as I reconnected the headset again, all became muted again.
The phone, its connectors, headphones are clean, free from dirt. I did try two almost unused Apple Earpods. I'm using latest iOS, ver 12.4.1.
I discovered also that all worked ok after restart exactly once. Later calls are muted. I reported the issue to Apple (https://www.apple.com/feedback/iphone.html) as a bug, but we all know that Apple does not reply nor comment. Soon we have iOS 13, maybe the bug is known and already fixed. I thing that the issue started after some update in August. It seems that the phone just almost disconnects the headset and fails to route audio to and from it.