Let $G$ be a group. Suppose there exists an integer $k>1$ and a non-identity permutation $\pi \in S_k$ such that for all $x_1, x_2 \cdots x_k \neq \mathbf{1} \in G$ we have that $x_1x_2x_3 \cdots x_k = x_{\pi(1)}x_{\pi(2)}x_{\pi(3)} \cdots x_{\pi(k)}$. Must $G$ be abelian?
This question is motivated by this. I've attempted to use Andrés technique in the linked post again here, but to no avail. I've also attempted to look at classical non-abelian groups like $S_3$ and $GL_n(\mathbf{C})$ for counterexamples but also to no avail.
If this is false, is it possible that there's some conditions on the permutation $\pi$ which makes this true? Because, again looking over the linked post, it is clear that some permutations force abelianness.