I can't see why the queen can't escape to d7 after Re6. Why does Stockfish show dxc3 as the better move? Does it have to do with white's kingside pawns?
lichess.org/training/80304White gets a large kingside attack after 20...Qd7? 21. Nxd5 Qxd5 22. g5!. Black might as well give up material to avoid it.
In general, you can analyze (or even play) against the AI to see "if I do this, what does the opponent do". So try the two moves (either in analysis mode or "play against the machine") and see how it goes?