If we take the region bounded by the $y$-axis, the $x$-axis, the line $x=a$ (with $a\gt 0$), and the parabola $y=x^2$, and rotate it about the $x$-axis, the volume of the resulting solid of revolution is easily computed (using, for example, discs perpendicular to the $x$-axis) to be $\text{Volume A} = \int_0^a \pi(x^2)^2\,dx = \frac{\pi}{5}x^5\Bigm|_0^a = \frac{\pi a^5}{5}.$ If the region bounded by the $y$-axis, the $x$ axis, the line $y=b$ (with $b\gt 0$), and the parabola $y=x^2$ is revolved around the $y$-axis, then using discs perpendicular to the $y$-axis we obtain the volume to be: $\text{Volume B} = \int_0^b \pi (\sqrt{y})^2\,dy = \frac{\pi}{2}y^2\Bigm|_0^b = \frac{\pi b^2}{2}.$ So your computations are correct there.
If the two volumes are the same, then we must have $\text{Volume A} = \frac{\pi a^5}{5} = \frac{\pi b^2}{2} = \text{Volume B};$ there are many ways to express this: you can solve for one of $a$ or $b$ in terms of the other: $b = \sqrt{\frac{2a^5}{5}} = a^{5/2}\sqrt{\frac{2}{5}},$ or, if you want to express $a$ in terms of $b$ instead, $ a = \sqrt[5]{\frac{5}{2}b^2} = b^{2/5}\sqrt[5]{\frac{5}{2}}.$ Or you can simply express this relation by saying, say $2a^5 = 5b^2.$
Note. If $a\lt 0$, then the volume of $A$ can be computed the same way, but the integral would go from $a$ to $0$, so that the volume would be $-\frac{\pi a^5}{5}$; to account for both possibilities, both $a\gt 0$ and $a\lt 0$, you can simply write that the volume is $\frac{\pi|a|^5}{5}$. For solid $B$, however, it makes no sense to talk about $b\lt 0$, because then we don't have a finite area "enclosed" by the curves in question.