Question is regarding following property of free modules:
Let $P$ be a free $R$ module. To every surjective homomorphism $f:B\rightarrow C$ of $R$ modules and to every homomorphism $g:P\rightarrow C$ there exists a homomorphism $h:P\rightarrow B$ such that $g=f\circ h$
$$\begin{array}{ccccccccc} P\\ \downarrow{h} & \searrow{g} & \\ B & \xrightarrow{f} & C \end{array}$$
Please feel free to edit the diagram to make it look better.
Let $S$ be a basis for $P$. Take $a\in S$, we have $g(a)\in C$. As $f$ is surjective, we have $b\in B$ such that $f(b)=g(a)$. Define $h(a)=b$. We them have $g(a)=f(b)=f(h(a))=(f\circ h)(a)$. Extend this linearly to whole of $P$.
It remains to prove that the map is well defined.
Suppose that $a_i\in S$ such that $\sum_{i=1}^na_i=0$. Linear independece of elements of $S$ implies that $a_i=0$. So, $h(\sum_{i=1}^n a_i)=\sum_{i=1}^n h(a_i)=0$.
Please let me know if this justification sufficient enough to say that $h$ is well defined?
If you have a basis $S$ for $P$, we know that $\operatorname{Hom}(P,C)\simeq C^S$, and similarly $\operatorname{Hom}(P,B)\simeq B^S$.
Now if for each $s\in S$, you choose an element $b_s\in B$ such that $\;f(b_s)=g(s)$ (we're using the axiom of choice here if $S$ is not finite), the family $\;(b_s)_{s\in S}\in B^S$ defines a homomorphism $h$ from $P$ to $B$, such that $f\circ h=g$ on $S$, hence on $P$.