I have been working with the group $\mathbb{Z}/2p^2\mathbb{Z}$ and would like someone to correct my reasoning below.
Let $p$ be an odd prime, and consider the multiplicative group $(\mathbb{Z}/2p^2\mathbb{Z})^\times$. This group is cyclic, and so contains some element $c$ of order $|(\mathbb{Z}/2p^2\mathbb{Z})^\times| = \phi(2p^2) = p(p-1)$.
Now let $b = c^{k(p-1)}$ be an element of this cyclic group of order $p$ (i.e. $k \neq 0$). I am trying to find the value $1 + b + \ldots + b^{(p-1)}$ (mod $2p^2$). All equalities below are mod $2p^2$.
First, we let $A = 1 + b + \ldots + b^{(p-1)}$, and note that: $A = b(b^{(p-1)} + 1 + b + \ldots + b^{(p-2)}) = bA$. Similarly, we have $A = b^kA$ for all $k$, and therefore $A = 1 + b + \ldots + b^{(p-1)} = 0$ since $b^k \neq 1$, in general.
I know (from computing some examples numerically) that this is incorrect - I suspect that the sum is actually equal to $p$ mod $2p^2$ - but can't see where my reasoning is off. Any comments would be welcome.
It seems that you are including $1$ in your sum, even though it has order $1$ and not $p$. That's fine though: given an odd prime $p$, define $A$ to be the sum of the elements of order dividing $p$ modulo $p^2$. You are correct that $A\equiv p\pmod{2p^2}$.
It's not hard to show that the elements of order $1$ or $p$ modulo $2p^2$ are $$ 1, 2p+1, 4p+1, \dots, 2(p-1)p+1. $$ Indeed, we know there are exactly $p$ such elements (since the multiplicative group is cyclic); and $$ (2kp+1)^p = \sum_{j=0}^p \binom pj (2kp)^j \equiv 1 + p\cdot2kp + \sum_{j=2}^p 0 \equiv 1\pmod{2p^2}, $$ so this list must be complete. (Alternately, use the fact that elements of order $p$ modulo $2p^2$ are precisely the $(p-1)$st powers, and any such integer must be congruent to $1\pmod p$ by Fermat's little theorem.)
From here we easily compute that $A = \sum_{k=0}^{p-1} (2kp+1) = p^2(p-1)+p\equiv p\pmod{2p^2}$.