People can, and have, killed in the name of almost anything, athesim and theism included.
Stalin didn't kill in the name of atheism, though; nor Mao. They both killed for a couple of different reasons. Firstly, they both were interested in eliminating rival power-bases. These killings were small in number and generally limited to the political class, such as in the Moscow show trials of the 1930s. Secondly, they both killed in order to instill terror in the populace. They wanted people afraid to raise their voice to complain about even the most trivial issue with governance, for fear of the GULag or re-education camp. These killing comprised a large proportion of the deaths in both regimes. Thirdly, they killed simply as a byproduct of brutal policies that weren't directly intended to kill, but had that as an effect -- say, heavy forced labor on scant rations, or forced resettlement of entire populations.
The only religious group I know of whom Stalin killed solely because of their religion were the Anabaptists, though there were no doubt others.
Stalin didn't kill in the name of atheism, though; nor Mao. They both killed for a couple of different reasons. Firstly, they both were interested in eliminating rival power-bases. These killings were small in number and generally limited to the political class, such as in the Moscow show trials of the 1930s. Secondly, they both killed in order to instill terror in the populace. They wanted people afraid to raise their voice to complain about even the most trivial issue with governance, for fear of the GULag or re-education camp. These killing comprised a large proportion of the deaths in both regimes. Thirdly, they killed simply as a byproduct of brutal policies that weren't directly intended to kill, but had that as an effect -- say, heavy forced labor on scant rations, or forced resettlement of entire populations.
The only religious group I know of whom Stalin killed solely because of their religion were the Anabaptists, though there were no doubt others.