If you are given a function $f:A\to B$, you are right that injectivity is "intrinsic" to the function, in the sense that it only depends on the graph of the function; while any function is surjective "onto its image".
Others have already explained why it can be unilluminating to look at the image of the function : sometimes (often) it's very hard to describe said image, and the question of surjectivity onto $B$ just becomes a question of equality : is $\mathrm{im} (f) = B$ ? As such, you're not solving the question by saying "oh it's surjective onto $\mathrm{im}(f)$", and this is the point I want to make : when asking for surjectivity of a function, you're often not interested in whether it's surjective somewhere, rather your real interest lies in the set $B$.
In other words, asking whether $f$ is surjective is not asking something only about $f$ (and its graph more specifically), it's asking whether the equation $f(x)=b$ always has a solution for $b\in B$. From that perspective, you can see why we're interested in surjections : they're the maps such that any equation is solvable.
Let me give you a couple of examples where the concept of surjectivity is interesting :
-Suppose you have a field $k$ (you can think $k=\mathbb{R,C,Q}$ if you don't know a lot about fields) and a polynomial function $P\in k[x]$. Then $P:k\to k$ and you may ask whether $P$ is surjective. Of course it's surjective onto its image, but that's not really what you want to know. Being even more specific, take $P(x) = x^2$, then asking whether $P$ is surjective is asking "does every element of $k$ have a square root in $k$ ?" Now that is quite clearly an interesting question (that lead to the discovery of $\mathbb{C}$ !), and obviously it's the same as "is $\mathrm{im}(P) = k$?", but again, phrasing it like this doesn't really help, and doesn't remove the interest of the question.
-If you know Cantor's theorem, then you know that for any set $X$ there is no surjection $X\to \mathcal{P}(X)$. Now without the notion of surjection this result isn't even expressible, whereas it's a very important statement. Of course any function $f:X\to \mathcal{P}(X)$ is surjective onto its image : but who cares ? what we're really interested in is whether every element of $\mathcal{P}(X)$ is attained.
In summary, surjectivity is an interesting notion when you're actually interested in the codomain, not only in the function : it indeed happens that sometimes you don't really care about $B$, you mainly care about $f$ and $A$, and in these cases you just say "corestrict to the image of $f$ and we're good"; but sometimes you're also interested in $B$, in which case the notion becomes relevant.
Let me end by noting that once you've asked the question of surjectivity, and, say, got a negative answer, the quest does not end here, because again, as you said, $f$ is always surjective onto $\mathrm{im}(f)$ : so if $f$ is not surjective onto $B$, it means that the equation $f(x)=b$ does not have a solution for all $b$, and so you enter a somehow more nuanced question, which is "for which $b$ does it have a solution ?" (which is of course the same question as "what is $\mathrm{im}(f)$ ?"; but perhaps phrasing it in terms of equations makes it clearer)