Question
Let G be a p group, such that $ |G|=p^n$. Prove that $ |Z(G)|\neq p^{n-1}$.
Beginning of Proof
So, I began by writing out $ p^n=|G|=\sum_{i\in I}[G:Stab_G(x_i)]+|Z(G)|=\sum_{i\in I}[G:Stab_G(x_i)]+p^{n-1}$, when $ \left\{x_i\right\}_{i\in I}$ are representatives in the following way $ \cup_{i\in I}x_iGx_i^{-1}\cup Z(G)=\cup_{x\in G}xGx^{-1}$, when $ \forall i\in I, |x_iGx_i^{-1}|\geq p$ (because otherwise $x_i \in Z(G)$). Therefore, $ \sum_{i\in I}[G:Stab_G(x_i)]=p^n(p-1)$.
Then, we can say that $ \forall i\in I, \exists j_i\in [1,n-1]: [G:Stab_G(x_i)]=p^{j_i}$, according to Lagrange's theorem. Since p-1 is even (if $ p\neq 2$), then in order for this sum of odd numbers to be even, then |I| must be even. Therefore, we can write that $|I|=2k$, when $ 2k \in [2,\frac{p^n(p-1)}{2}]$. $2k\neq p^n(p-1)$, because then, we'll have $p^n(p-1)$ numbers in the sum, and therefore every number in the sum must be 1, such that $\forall i\in I, |Stab_G(x_i)|=|G| \Rightarrow x_i\in Z(G)$. Therefore, $k\in [1,\frac{p^n(p-1)}{4}]$, and therefore, $p-1\equiv 0 (mod 4) \Rightarrow p \equiv 1 (mod 4)$. Therefore, $ |Z(G)|\neq p^{n-1}$, for $p: p \equiv 3(mod 4)$.
I haven't been able to prove this for all other primes p. Thanks a lot for the help!!!