This argument is mostly contained in t3suji's comments, but with some of the proofs somewhat expanded.

As a convention (consistent with that of the theory of Chow motives), all actions of correspondences $\alpha \in \operatorname{CH}^*(X \times Y)$ on cohomology (or Jacobians) are *covariant*: $\alpha_* \colon H^*(X) \to H^*(Y)$, etc.

**Lemma.** If $X$ and $Y$ are smooth projective varieties over $\mathbb C$, then there is an isomorphism
$$\operatorname{NS}(X \times Y) \cong \operatorname{NS}(X) \times \operatorname{NS}(Y) \times \operatorname{Hom}(\operatorname{Alb}_X,\operatorname{Pic}^0_Y).\label{Eq NS}\tag{1}$$

*Proof.* The Künneth formula gives an isomorphism of $\mathbb Z$-Hodge structures
$$H^2(X \times Y) = \big( H^2(X) \otimes H^0(Y)\big) \oplus \big( H^0(X) \otimes H^2(Y) \big) \oplus \big( H^1(X) \otimes H^1(Y) \big).\tag{2}\label{Eq Künneth}$$
By Poincaré duality, the last term equals $\operatorname{Hom}(H^{2\dim X-1}(X),H^1(Y))$. Taking $(1,1)$-parts in (\ref{Eq Künneth}) gives the result by Lefschetz's (1,1) theorem and the theory of abelian varieties over $\mathbb C$. $\square$

There is also a version for $\operatorname{Pic}$ for smooth projective varieties over an arbitrary field (or even over a base, under some mild hypotheses to ensure existence of $\operatorname{\textbf{Pic}}_{X/S}$ and $\operatorname{\textbf{Alb}}_{X/S}$). The above analytic proof has the advantage that it shows us how classes act on Jacobians: if $X$ and $Y$ are curves, then $\operatorname{Alb}_X \cong \operatorname{Pic}_X^0 \cong \operatorname{Jac}_X$, and under these identifications, a class $\alpha \in \operatorname{CH}^1(X \times Y)$ induces the map $\alpha_* \colon \operatorname{Jac}_X \to \operatorname{Jac}_Y$ given by the corrresponding component of $\alpha$ under (\ref{Eq NS}).

**Construction.** Let $A \subseteq \operatorname{Jac}_C$ be any abelian subvariety. Let $E$ be any curve admitting a surjection $\operatorname{Jac}_E \to A$; for example, $E = C$ with the projection $\operatorname{Jac}_C \to A$ given by $n \pi$ for $\pi \in \operatorname{End}^\circ(\operatorname{Jac}_C)$ the projector corresponding to the isogeny factor $A$ of $\operatorname{Jac}_C$, and $n \in \mathbb Z_{> 0}$ such that $n\pi$ is integral. The composition gives a morphism $\phi \colon \operatorname{Jac}_E \to \operatorname{Jac}_C$, corresponding by (\ref{Eq NS}) to a class $\alpha \in \operatorname{NS}(X \times Y)$.

The class $(1,1,0)$ in (\ref{Eq NS}) is ample, hence for some $n \gg 0$ there exists a very ample line bundle $\mathscr L$ on $X \times Y$ mapping to $(n,n,\alpha) \in \operatorname{NS}(X \times Y)$. Let $D \in |\mathscr L|$ be a smooth member. By the discussion above, the cycle $[D] \in \operatorname{CH}^1(E \times C)$ induces the map $\phi$.

The graphs of the maps $g \colon D \to E$ and $f \colon D \to C$ give cycles $[\Gamma_g]^\top \in \operatorname{CH}^1(E \times D)$ and $[\Gamma_f] \in \operatorname{CH}^1(D \times C)$, whose actions on $\operatorname{Jac}$ are given by $g^*$ and $f_*$ respectively. Moreover, we have
$$[\Gamma_g]^\top \circ [\Gamma_f] = [D] \in \operatorname{CH}^1(E \times C),$$
which shows that indeed $\phi = f_* \circ g^*$. $\square$

1more comment