Suppose $R$ is a commutative unital ring, $G$ a finite group, and $H$ a subgroup of $G$ whose order is invertible in $R$. Defining $e_H=|H|^{-1}\sum_{h\in H} h$, why is $RG/H\simeq e_HRG$?
This comes up in some reading showing that invariants and coinvariants of a representation can coincide.
I observed that $e_H$ is idempotent, and $e_Hh=e_H$ for all $h\in H$. I thought maybe the projection map $RG\to e_HRG:x\mapsto e_Hx$, would descend to an isomorphism somehow. It sends all of $H$ to $e_H$, but I'm not sure if this argument goes anywhere.
Define $\phi:R[G/H]\to e_HRG$ by $\phi(g+H)=e_Hg$ (extended by $R$-linearity). First, it is well defined because, as you noted, $e_Hh=e_H$ for every $h\in H$. Surjectivity of $\phi$ comes immediatly. I let you prove injectivity.