This statement is false. The weight, or more correctly mass, of an atom comes mostly from the subatomic particles in the nucleus - the proton and the neutron. The mass of the electron is about 1/1840 that of a proton or neutron. The nucleus or center of the atom takes up a very small amount of the atom's volume yet accounts for virtually all of its mass. The majority of the atom is empty space in which the very tiny electrons moving about.
When determining the mass of an atom to the nearest whole number, we count the number of protons and neutrons but don't count the electrons. For example, an atom of carbon that contains 6 electrons, 6 protons and 6 neutrons has a mass of 12 amu (atomic mass units), the sum of the protons and neutrons.