So I had to find the condition (for $a$, $b$, $p$; $p$ is prime) when $$ (condition) \iff (a^2+b^2 \equiv 0\mod p \Rightarrow a^2+b^2 \equiv 0 \mod p^2)$$ is true.
When $a \equiv 0\pmod p$ and $b \equiv 0\pmod p$ it is always true, but there are non-trivial cases when $a \neq 0\pmod p$ and $b \neq 0\pmod p$ and the implication is correct (ex. $a = 3, b = 4, p = 5$)
I tried to express $a^2+b^2 \equiv 0\pmod p$ as: $$(q_1*p + r_1)^2 + (q_2*p + r_2)^2 \equiv 0 \pmod p$$ where $r_1$ and $r_2$ in $[-\frac{p-1}{2}; \frac{p-1}{2}]$ to get: $$p^2(q_1^2+q_2^2) + 2p(q_1*r_1 + q_2*r_2) + (r_1^2+r_2^2) \equiv 0 \pmod p$$ The only thing I realised is that $r_1^2 \equiv -r_2^2 \pmod p$ and I don't know what to do next.
Also, it may be useful: for every $p= 4k+3$ this implication works because for these primes a and b can only be congurent to $0$ mod $p$ and every $p=4k+1$ it is true that: $a^2+b^2 = p$ has a unique soultion with $a\le b$ but I have not managed to do sth with it yet(