A surface is a 2-dimensional manifold. Unfortunately, that sort of begs the question. There are different ways to represent surfaces, which may give misleading impressions about their dimensionality. Some different ways surfaces may be obtained:

Explicitly, as the GRAPH of a function $f: \Bbb R^2 \to \Bbb R$, typically written $z = f(x,y)$. For example:

$z = x^2 + y^2$, which is an elliptic (circular, actually) paraboloid.

Parametrically, as the IMAGE of a (non-degenerate) function $p: \Bbb R^2 \to \Bbb R^n$. For example the sphere can be described as the image of:

$p(u,v) = (r\sin u\cos v,r \sin u \sin v, r\cos u)$

Implicitly, as the set of zeros for a function $g: \Bbb R^3 \to \Bbb R$. An example of this is another version of the sphere:

$g(x,y,z) = x^2 + y^2 + z^2 - r^2$, when $g(x,y,z) = 0$, we obtain the (implicitly defined) functions:

$f_1(x,y) = \sqrt{r^2 - x^2 - y^2}$

$f_2(x,y) = -\sqrt{r^2 - x^2 - y^2}$

which are "implied" by the condition: $x^2 + y^2 + z^2 = r^2$.

In your problem, the latter situation is the case for $A$, the "$g$" is: $g(x,y,z) = x^2 + y^2 + z^2 - 9$., and the first situation is what we have for $B$, where $f(x,y) = x^2 + y^2 - 3$.

It is not uncommon for different ways to represent surfaces to be used in a "mix and match" scenario, depending on what facilitates calculation.