It's like with "vestido," which is a masculine noun. It does not matter whether it is "ella" wearing it or "él" as far as agreeing genders is concerned. The gender of who might be wearing a dress, that is a noun thing, has no correspondance to how genders must correspond, like with a dress being of a white color where this would be "blanco" and not "blanca" because "vestido" is of a male gender..
They gave me one question, and when I answered it correctly, they said it was wrong, and the results they reveild had a different question all together! ,They corrected me on a different question , than they gave me at the begining question they asked me! Has this happened to any one else?