A chess engine on PC is almost deterministic in its move results if...
You play with 1 thread only;
you switch off all parameters that guide move variety like Position Learning, Book Learning, Hashtables, MultiPV;
keep the usage of Endgame Tablebases on;
if possible switch off NNUE and MCTS to force the computer to use its own coded routines (not possible with every engine.)
Despite of all that, some engines have a randomness in their code with which they process the possible moves, some make a ranking hitlist after the main calculated variation that is different each time, in this case you cannot get a secure repetition of a move in a specific time frame.
You would also have in each case to make the computer move after a fixed time bypassing the variety of different response times - as said above, best is to set a precise nodes-per-move calculation.
So far for my answer, but commenting on your "go back and try different moves to see how they effect the game", I don't think that doing all this is really necessary for that purpose.