it is possible to apply echo cancellation to microphones while they are recording, e.g. like this
How can I apply the same filter to audio files that already exist?
If there was a ffmpeg filter for this, it would be applied like this:
ffmpeg -i FileWithEcho.mp3 -v $module-echo-cancel FileWithoutEcho.mp3