I have been having the same problem. It turns out (in my case), that if I plug a headset with a microphone in, then it works. If this is the case for you too, it could be a hardware problem. The microphone is located on the backside of the USB-C side board. I ordered a new one and installed it today. Thankfully it fixed the issue and the (new) internal microphone is now working.
***Instructions:*** To replace the USB-C side board, you need to follow steps 1-5 of replacing the main board. Then the USB-C side board is glued in place, as explained in the note about the vibration motor.
''Note: Doing the replacement yourself is a bit fiddly and requires the right precision tools, but definitely doable.''
* USB-C side board replacement: [link|https://pine64.com/product/pinephone-usb-c-side-board/|https://pine64.com/product/pinephone-usb-c-side-board/|new_window=true]
* Steps 1-5 replacing the main board: [link|https://wiki.pine64.org/index.php/PinePhone#Swapping_in_a_new_mainboard_revision|https://wiki.pine64.org/index.php/PinePhone#Swapping_in_a_new_mainboard_revision|new_window=true]