It is known that there exist rings $R$ for which $R^{\oplus n}\cong R^{\oplus m}$ (as $R$-modules) even if $n\neq m$. For instance, take $R = \text{End}_F(V)$ where $F$ is a field and $V$ is an infinite-dimensional vector space over $R$ (for details, see here). Consider therefore, the following argument that all rings have IBN (invariant basis number).
Let $R$ be any ring, and suppose $R^{\oplus n}\cong R^{\oplus m}$ as left $R$-modules. Let $V$ be any simple left $R$-module (for instance, take $V = R/I$ where $I$ is any maximal left ideal of $R$). Then we have $$V^{\oplus n}\cong R^{\oplus n}\otimes_RV\cong R^{\oplus m}\otimes_RV \cong V^{\oplus m}.$$ We may write down composition series for $V^{\oplus n}$ and $V^{\oplus m}$: $$V^{\oplus n}\supsetneq V^{\oplus (n-1)}\supsetneq \cdots\supsetneq V^{\oplus 1}\supsetneq V \supsetneq 0 \qquad\text{ and} \\ V^{\oplus m}\supsetneq V^{\oplus (m-1)}\supsetneq \cdots\supsetneq V^{\oplus 1}\supsetneq V \supsetneq 0.$$ By the Jordan Hölder theorem, since $V^{\oplus n}\cong V^{\oplus m}$, we have that $$n = \text{length}(V^{\oplus n}) = \text{length}(V^{\oplus m}) = m.$$
Can anyone find the mistake in the argument?