Welcome to Android Central! Which phone, which keyboard app, and which messaging app? I use Gboard on my Pixel 7 Pro, and the mic icon is still in the usual place -- at the upper right (next to the settings icon for Gboard).
Welcome to AC!
If you have a Samsung and on One UI 6.1 Samsung changed this the only alternative at the moment using different keyboard like Gboard or Swiftkey.