Queen Guinevere was judging the knight. It was her who urged Arthur not to have him executed, and it was her who gave the knight the task to find the answer what is it that women most want.
The fact that the queen had it her way speaks for itself. The story is a proto-feminist one, and its point - that women want to be in control of their own lives - is in line with this. Although, being the king, Arthur has the supreme power and authority, he knows that his wife is more competent when it comes to punishing the knight for raping a woman.