If $p$ is prime, then $x^2 +5y^2 = p \iff p\equiv 1,9 $ mod $(20)$.

An alternative solution: the class number of $K=\mathbb{Q}(\sqrt{-5})$ is $2$, its Hilbert class field is $L=\mathbb{Q}(\sqrt{-5},\sqrt{-1})$. A prime $p\neq 2,5$ can be written as $p=x^2+5y^2$, iff $p$ splits into two principal prime ideals in $K$, iff $p$ splits completely in $L$, iff $p$ splits in both $\mathbb{Q}(\sqrt{5})$ and $\mathbb{Q}(\sqrt{-1})$, iff $$\left(\frac{-1}{p}\right) = 1 \qquad \left(\frac{5}{p}\right)= \left(\frac{p}{5}\right) = 1$$ which happens iff $p\equiv 1,9 \pmod{20}$.


The solution using reduced binary quadratic form works here, because when $D=-20$ there are only one form $x^2+5y^2$ in the principal genus. This also happens for some other small $|D|$.


Let $p\equiv1$ or $9\pmod{20}$. Then $-5$ is a quadratic residue modulo $p$, so there are integers $r$ and $s$ with $$r^2+ps=-5.$$ This means that the integer quadratic form $$f(X,Y)=pX^2+2rXY+sY^2$$ has discriminant $-20$ and is also positive definite. Then $p$ is represented by $f$. Now $f$ is equivalent to a reduced form. There are two reduced forms of discriminant $-20$: $g_1(X,Y)=X^2+5Y^2$ and $g_2(X,Y)=2X^2+2XY+3Y^2$. But $g_2$ cannot represent any number congruent to $1$ or $9$ modulo $20$. Therefore $g_1$ represents $p$.