A pile contains $2021^{2021}$ stones. In a move any pile can be divided into two piles so that the numbers of stones in them differ by a power of $2$ with non-negative integer exponent. After some move it turned out that the number of stones in each pile is a power of $2$ with non-negative integer exponent. Prove that the number of moves performed was even.