「あなた は おんな じゃ ありません。おとこ です 。」
is perfectly correct.
(Except that the situation is a bit weird. Who needs to be declared that himself is not a woman, but a man? lol)
Anyway, ありません in these two example sentences are working for different purposes.
あなたは おんなじゃ ありません。
ほんが ありません。
Look at the particles. The first one is ~~じゃ ありません,
while the second one is ~~が ありません。
「AはBじゃ(also, では in formal speech) ありません」denies the state of being. In short, "A is not B." In this usage, we don't use いません no matter whatever the subject is. The affirmative sentence becomes 「 AはBです」(You can also say 「AはBであります.」, but it sounds too formal, so it's rarely used. )
わたしは にほんじん です。
あなたは にほんじん じゃありません。
Next, 「(Aに/Aは)Bが ありません」denies the existence of B. In short, "There is no B (with A/at A/in A etc. )" In this usage, you use あります/ありません for inanimate things like books or chairs, and you use います/いません for animate livings like people, animals.
かばんのなかに ほんが あります。(×います)
いすのしたに ねこが いません。(×ありません)