A simple solution is to buy the Vmoda BoomPro Microphone. This will give you a regular mini jack connector that you can plug into your computer. I use this solution for my WH-1000xM3's. Bluetooth always adds lag and this is terrible for gaming.
Headphones
A community for discussion around all topics related to headphones and personal audio.
Absolutely terrible in all aspects.
If you want to use wireless headphones for gaming at your PC you'll want to get something intended for the purpose that uses a low latency wireless protocol and has a special dongle for it. Even ignoring the latency issues the WH-1000XM4 sound like shit, their mics are shit compared to a headset, and their build quality is poor.
Look at something like the HyperX Cloud Alpha if it's got to be wireless.
They are very good for single story driven games, as well as for movies. They have Sony's sound signature - bassy, soften treble, and decessed mids, but you have EQ for tuning and you can easily find typical eq settings for Harman curve or others. I use them as with BT, as with not wired gamepad mini jack (PS5 Dualsense, and PC xbox one controller with MS adapter). No noticeable latency in both cases. My BT cases are not standard. First case: I use Shield for streaming and in this case headphones connect to the Shield in LDAC mode. And this is really OK. Second case: I use Fiio BTA30 connected by optical cable to TV. Headphones connect to bta30. Sound is passing from PS5 through TV to BTA30 and LDAC. In this case the sound is a bit better than from gamepad minijack. About spatial audio - seems to me not working.