TITLE: Divisor of a finite group
QUESTION [9 upvotes]: Suppose we have a finite group $G$ and $d\in \mathbb N$ is a divisor of $|G|$. We define the set $E_d= \{g\in G : g^d =1\}$. Prove that $d$ is also a divisor of $|E_d|$.

So far I proved that $E_d=\displaystyle \bigcup_{g\in G : o(g)\vert d} \langle g \rangle$ but I didn't know how to continue from here and if this equality is helpful or not. 
I will appreciate any help. Thank you.

REPLY [4 votes]: This is a theorem of Frobenius. He proved:
Theorem (Frobenius 1903): Let $d$ be a divisor of $|G|$ and $a_d$ be the number of elements of order dividing $d$. Then $a_d$ is divisible by $d$.
Note that $a_d=|E_d|$. A proof of this theorem is given, for example, by K. Brown here in Corollary $1.6$. The proof uses that
$$
a_d=\sum \mu (H,K) |H|,
$$
where $H$ and $K$ range over subgroups of order dividing $d$, obtained by Moebius inversion formula applied to the equations
$$
|H|=\sum_{K\le H}f(K),
$$
where $f(K)=0$, if $K$ is not cyclic, and $f(K)=\phi(k)$, if $K$ is cyclic of order $k$. For a detailed proof see the article On the Moebius function of a finite group by Hawkes et al, Theorem $6.3$.
Edit: The comments refer to an ealier answer.