The answer is no.

Any surface of degree $d$ passing through the lines is of the form $l_1 Q_1+l_2Q_2$ where $Q_1,Q_2$ are homogeneous polynomials of degree $d-1$.

Since the line does not intersect the curve $C$, the curve $C$ is not in a plane passing through the line. Hence, neither $l_1$ neither $l_2$ vanishes on $C$. <b>But</b> this does not imply that $Q_1,Q_2$ vanish on $C$.

To have a precise counterexample, I take coordinates $[w:x:y:z]$ on $\mathbb{P}^3$, define $l_1=w$, $l_2=x$, and take $C$ to be the twisted cubic being the image of the morphism $\mathbb{P}^1\to \mathbb{P}^3$ given by $[u:v]\mapsto [uv^2:u^2v:u^3:v^3]$. Then
$wy-x^2$ vanishes on $C\cup l$ but is not of the form $wR+xS$ with $R,S$ vanishing on $C$. Indeed, $R,S$ would be of degree $1$ and not polynomial of degree $1$ vanished on $C$.