I had same problem last month. I replaced my battery and then the mic at bottom stopped working. But when I use it on speakerphone,people can hear me (I know it is using the secondary mic as there are 2 mics in the phone)
Well I replaced the charger port at the bottom which also houses the mic. Now my speaker phone and mic aren’t working. I put my old part back in and speakerphone works now but still no mic. I bent the tabs for the speaker phone and still not working on the new part. . Put my old part in waited for a replacement. Installed replacement one today. Speakerphone is now working with new part but still no mic working at bottom when talking into it normally. People can only hear me on speakerphone. I’ve come to the final conclusion that my logic board went bad. I am not sure how as I never dropped it and have been selling and repairing phones for 12 years. Gonna sell it for parts on Ebay now. I saw another seller with same exact issue. He replaced the same part I did and still no one can hear him on the bottom mic. You can try replacing the mic assembly at the bottom. It’s only $2.45 on eBay. It’s worth a shot. There are YouTube videos showing you how. I did mine in 15 mins in and out. Just line the screws up on a cloth so you know which ones go where. They are all different sizes. When I removed my battery I did notice a small piece of solder came out of the phone housing when I had it apart to replace it. Maybe this came off the mic part of the logic board or just a coincidence. Either way, I tried 2 different new bottom mic/charger port assembly’s and both didn’t fix it. I give up.