Let $\varphi(n)$ denote the number of natural numbers less than $n$ that are relatively prime to $n$, and $\sigma(n)$ denote the sum of the divisors of $n$. Determine all exponents $k$ for which

$$
\varphi\left(\sigma\left(2^{k}\right)\right)=2^{k}
$$

holds. (As a hint, we reveal that 641 is a divisor of $\left(2^{32}+1\right)$.)