If someone stole a pile of valid ballots, and filled them out and stuffed them, how would the recount be able to separate valid ballots from invalid ballots?
You mean already filled ones from the box or blanks? Hopefully somebody will see you trying to steal a bunch of filed ballots during the counting. Blanks are counted and there shouldn't be any missing.
If there are too many ballots counted (compared to the number of people who voted) there may be a re-voting (if the results are close enough to warrant this).
However, it is advised that if you do not care who wins (or all choices for you are bad) you still should go and then invalidate your ballot, to make it even harder for someone to vote "for you".
Also, sometimes during counting they may find "suspicious" ballots, for example a bunch of ballots seemingly filled with the same handwriting. It may trigger an investigation.