If an atom gains an electron, shouldn't it be positively charged since it might now want to give away its extra electron. But it is also considered to be negatively charged due to presence of excess electrons
an atom gets negative charge by gaining the electrons.
and an atom gets positive charge by donating electrons.