First note that for example the congruence $x^2\equiv y^2 +1 \pmod{1}$ has $2$ solutions, and $x^2 \equiv y^2+0$ has $2$ solutions, so the result is not correct when $p=2$. However, it is correct when $p$ is an odd prime, so from now on assume that $p>2$.
By a direct calculation, what I would mean is a genuinely direct calculation, without any Legendre symbol stuff. Arturo Magidin has done the harder part. We deal with the case $a\equiv 0\pmod{p}$.
Since our congruence is equivalent to $x^2-y^2\equiv a \pmod{p}$, we are solving $(x-y)(x+y)\equiv 0\pmod p$.
To count the solutions, note that we can (i) let $x-y$ have any non-zero value $b$, ($p-1$ possibilities) and let $x+y\equiv 0$, or (ii) let $x-y \equiv 0$, and let $x+y$ take on any non-zero value, or (iii) let $x-y$ and $x+y$ each be congruent to $0$.
In the first case, $x-y\equiv b$, $x+y\equiv 0$ has a unique solution. This is where things break down in the case $p=2$, for you will recall from high-school algebra that solving $x-y=c$, $x+y=d$ involves dividing by $2$.
So there are $p-1$ type (i) solutions, $p-1$ type (ii) solutions, and $1$ type (iii) solution, for a total of $2(p-1)+1$. Alternately, count the solutions with $x-y\equiv 0$ (there are $p$ of them), the solutions with $x+y \equiv 0$ (another $p$). Add. But we have double-counted $(0,0)$, so the correct answer is $2p-1$.
A Legendre symbol calculation will also work. The only problem is that it somewhat distances us from what is going on.
For the case $a\equiv 0$, we want $\sum^{p-1}_{y=0}\left(1+\left(\frac{y^{2}+0}{p}\right)\right)$ (I have used your expression, with outer parentheses added.) This is $\sum^{p-1}_{y=0} 1 + \sum^{p-1}_{y=0}\left(\frac{y^{2}}{p}\right).$ The first sum is obviously $p$. For the second, note that $\left(\frac{0}{p}\right)=0$, and if $y\not\equiv 0$, then $\left(\frac{y^2}{p}\right)=1$, so the second sum is $p-1$.