We prove the following generalized claim:
Claim. Assume that $AB - BA = B^p$ for some $p \geq 2$. Then $AB = BA$.
This is equivalent to proving that $B^p = 0$. To this end, we notice that
$\operatorname{tr}(B^p) = \operatorname{tr}(AB - BA) = 0$ since $\operatorname{tr}(AB) = \operatorname{tr}(BA)$.
We have $\det(B^p) = 0$. Indeed, if $\det(B^p) \neq 0$, then $B$ is invertible. Multiplying $B^{-p}$ to the left, we have
$$B^{-p}AB - B^{1-p}A = I_2.$$
But this is impossible since
$$2 = \operatorname{tr}(I_2) \neq \operatorname{tr}((B^{-p}A)B - B(B^{-p}A)) = 0.$$
Applying Cayley-Hamilton theorem, we find that $B$ is nilpotent:
$$B^{2p} = \operatorname{tr}(B^p)I - \det(B^p)I_2 = 0.$$
Therefore we must have $B^2 = 0$ and hence $B^p = 0$. ////
Addendum: Counter-example for $p = 1$. For any $a_1, a_2, b \in \Bbb{C}$ with $b \neq 0$, put
$$ A = \begin{pmatrix} a_1 & a_2 \\ 0 & a_1 - 1 \end{pmatrix}, \qquad B = \begin{pmatrix} 0 & b \\ 0 & 0 \end{pmatrix}. \tag{*} $$
Then $AB - BA = B$.
Conversely, if $A, B \in M_2(\Bbb{C})$ is such that $AB - BA = B$ and $B \neq 0$, then $A$ and $B$ can be written as $\text{(*)}$ up to unitary change of basis.
(Remark. Using the Jordan normal form, it is straightforward that this is true up to change of basis.)
Indeed, since $\det(B) = 0$, $B$ has rank 1 and we may write
$$ B = b \begin{pmatrix} u_1 \bar{v}_1 & u_1 \bar{v}_2 \\ u_2 \bar{v}_1 & u_2 \bar{v}_2 \end{pmatrix} $$
for some $b \neq 0$ and for some unit vectors $u = (u_1, u_2), v = (v_1, v_2)$. Then $\operatorname{tr}(B) = 0$ is equivalent to $\langle u, v \rangle = 0$ and hence $u, v$ are orthogonal. In particular, $B$ corresponds to the linear map
$$ Bx = b\langle v, x \rangle u. $$
(Here, the 2nd argument of the Hermitian inner product $\langle \cdot, \cdot \rangle$ is chosen to be linear.) Then the claim follows by rewriting everything w.r.t. the orthonormal basis $\{u, v\}$ and solving the equation $AB - BA = B$.