The maximum order of the elements of a group and the number of elements that have that order
I was reading this article about the number of elements that have the maximum order of a group, where it proves that if you have a group $G$ and if $m = \max\{o(g) : g ∈ G\}$ is finite and exactly $k$ elements of $G$ have order $m$, where $k$ is finite, then G is finite and we have the following upper bound $$ |G| ≤\frac{mk^2}{\varphi(m)}. $$ And then says the following:
Using the notation of Theorem A, we note that if $G$ has exactly $k\leq\infty$ elements of maximum order, then there are only finitely many possibilities for $m$ since $\varphi(m)$ divides $k$.
Where Theorem A is the theorem mentioned above. My question is if the fact that $\varphi(m)|k$ is true and why.
It seems to me that this could be true for finite groups but again I don't know the proof if there is one. Also if this is false I would be grateful if someone could give a counterexample.
The group $A=(\mathbb{Z}/m\mathbb{Z})^\times$ acts on the set $E$ of elements of order $m$ via $(\bar{s},g)\in A\times E\mapsto g^s\in E$.
Note that if $g^s=g$, then $g^{s-1}=1$, so $m\mid (s-1)$ and $\bar{s}=\bar{1}$. In other words, the stabilizer of $g$ under the action of $A$ is trivial, and the orbit-stabilizer theorem then says that the orbit of $g$ has exactly $\vert A\vert=\varphi(m)$ elements.
Since $E$ is the disjoint union of its orbits, its cardinal $k$ is a multiple of $\varphi(m)$.