I would try adding ffmpeg to path, setting your working directory to the output folder, and running the script from there. If that doesn't work then you probably need to tweak the script.
The script page you linked also gives example syntax of
for %f in (*.mp4 *.avi *.mov) do ffmpeg -i "%f" -c:v libx264 -c:a aac "%~nf_new.mkv"
Did you try modifying the very last argument to something like "c:/your/path/%~nf_new.mkv"?