This is after your SWH, but I thought I would post this... I'm glad you rethought your initial punishment, and talked to him first.
When my daughter was in 5th grade, she was accused of changing her answers on a homework assignment (accused of changing it AFTER it was graded, for just a few points more.)
I had gone over that assignment with her, and she had initially gotten it wrong, and when I told her she needed to redo that question (math problem), she looked at it and said, "Oh.. I see what I did wrong!" She changed the answer at that point.
When it was graded the next day in class (trade and grade... someone else graded it for her), the other student marked it wrong. My daughter, in looking it over, tried to point out to the teacher that the student had graded it wrong.... and the teacher accused her of "changing" her answer just to get a couple of extra points.
What my daughter had done was not erase the answer fully, but marked over the first answer by just writing over the initial answer, and darkening it.
My daughter was rightfully upset about the teacher's accusation, and when I tried to talk to the teacher about it, she wouldn't back down. I even pointed out that I had checked her paper the night before, and she had the right answer... teacher still wouldn't back down. I also mentioned that the student grading her paper had a bit of a vendetta against my daughter, and the teacher still wouldn't change her position. I also asked the teacher if there was anything that my daughter had done in the past to make her not believe her side of the story... and the teacher's response? "Oh, no.... She is one of the most honest students I know!" (Why couldn't the teacher back down on just 2 homework points? Sheesh....)
It did really upset me..... and made my daughter feel that she couldn't go to the teacher the rest of the year with any problems.
Ultimately, when I told my daughter about it, her response was.. "That's ok.... I know I wasn't cheating, and God knows I wasn't cheating." What a mature response! (She wasn't saying God as a swear word... she was really meaning that God knew she hadn't cheated.....)
Anyway, I didn't punish her.... in that case, I totally believed my daughter...
Also... the next year, when I found out that daughter #2 was going to have that SAME teacher, I requested a teacher change... I felt that #2 would not have been comfortable with her, knowing what had happened....
I have a feeling that your son has learned a lesson from this already.... he is getting punishment from the school, and most likely, the teacher will be keeping a close eye on him for future events.... I would tend to believe his side of the story, especially if he had already finished the test.
A minor punishment at home would most likely be sufficient, with a written apology to the teacher.