Cortés is a Spanish surname that comes from the word cortés, which is Spanish for courteous. Cortez is obviously a variant of this surname, but I don't have any info on how it came to be, handy, sorry. Perhaps someone can help you out at
http://surnames.behindthename.com/