Setup: In the category $\mathsf{SET}$, given a pair of functions $f_1 : U_1 \to X$ and $f_2 : U_2 \to X$, it is obvious that $\mathrm{Im}\; f_1 \cup \mathrm{Im}\;f_2 \subset X$. For the sake of brevity I call $\mathrm{Im}\; f_1 \cup \mathrm{Im}\;f_2 = U_1 \cup_X U_2$ and call it a joint image of $f_1$ and $f_2$. This construction can be recreated as a pushout of the diagram $U_1 \xleftarrow{\pi_1} U_1 \times_X U_2 \xrightarrow{\pi_2} U_2$, where $U_1 \times_X U_2$ is a pullback of the diagram $U_1 \xrightarrow{f_1} X \xleftarrow{f_2} U_2$. So we can define joint image $U_1 \cup_X U_2$ as a colimit in an arbitrary category $\mathcal{C}$. If $U_1 \cup_X U_2$ exists then there is always an arrow from $U_1 \cup_X U_2$ to $X$ by universal property (take $f_1$ and $f_2$), say $f$. In the category $\mathsf{SET}$ the morphism $f$ is just a subset inclusion $\mathrm{Im}\; f_1 \cup \mathrm{Im}\;f_2 \hookrightarrow X$. So it is expected that $U_1 \cup_X U_2$ would a subobject of $X$ in an arbitrary category $\mathcal{C}$, which admits its existence. But can't recall anything which can prove it.
Motivation: My initial goal was to prove that if $f_1$ and $f_2$ are jointly epic, then $U_1 \cup_X U_2 \cong_{\mathcal{C}} X$. It is not hard to prove, that in this case $f$ is an epimorphism itself. But in order to complete the proof I need to show that $f$ is monic.
Comment: On the other hand I noticed that $U_1 \cup_X U_2$ is constructed more like a quotient of $U_1 \sqcup U_2$ and not as a subset of $X$. So it may be more appropriate to talk joint coimage and not a joint image. It is well known fact that the coimage and image coincide in many categories like $\mathsf{SET}$ but they are different, for example, in $\mathsf{TOP}$, a category of topological spaces. So $f$ may not be monic in general.
Question: Is there any reasonable condition on the category $\mathcal{C}$ or morphisms $f_1$ and $f_2$ that the morphism $f$ is monic?