@Unfortunately It's not mental, it's behavior based, but yes.
If I am a man but I enjoy playing with dolls, putting on makeup, and I experience joy when I take care of other people (which is a result of hormones frequently found in women more than men), if I spend my time perfecting my appearance, if I wear skirts, etc. IN SHORT: if I exhibit behavior frequently shown by females then;
Sex = male, gender = female.
HOWEVER I need to warn you that you shouldn't go around calling people that exhibit female behavior as a male (or vice versa) as female, because I'm sure not everyone will appreciate that.
If I am a man but I enjoy playing with dolls, putting on makeup, and I experience joy when I take care of other people (which is a result of hormones frequently found in women more than men), if I spend my time perfecting my appearance, if I wear skirts, etc. IN SHORT: if I exhibit behavior frequently shown by females then;
Sex = male, gender = female.
HOWEVER I need to warn you that you shouldn't go around calling people that exhibit female behavior as a male (or vice versa) as female, because I'm sure not everyone will appreciate that.