Pushing-forward morphisms Let $f\colon X\to Y$ be a surjective morphism of algebraic varieties, defined over an algebraically closed field.
We take a morphism $\psi\colon X\to Z$, where $Z$ in another algebraic variety, that satisfies the following condition: for all $x,x'\in X$, $f(x)=f(x')\Rightarrow \psi(x)=\psi(x')$.
This yields the existence of a unique map $\psi'\colon Y\to Z$ such that $\psi=\psi'\circ f$. What are conditions on $f$ we can put on $f$ to be sure that $\psi'$ is a morphism of algebraic varieties?
Of course, if $f$ is an isomorphism, the result is true. But is for example enough to ask that $f$ is non-ramified? Or another local condition?
I would be happy by only considering the case where $f$ is quasi-finite, even if the general case seems also interesting.
 A: You need to assume that $Y$ is normal (see the counterexample at the end), and you need to assume that the characteristic is $0$, or else Frobenius morphisms are counterexamples. Also, assume that $f$ is quasi-finite (the reduction to the case that $f$ is quasi-finite is at the end).  First of all, using Nagata compactification, $Z$ embeds as a dense open in a proper variety; replace $Z$ by this proper target. To prove a set map is an algebraic morphism, there is no harm in making the target bigger.  
Consider the product morphism $$(f,\psi):X\to Y\times Z.$$  By your hypothesis, $(f,\psi)$ is quasi-finite.  Thus, by Grothendieck's form of Zariski's Main Theorem, there exists a factorization of $(f,\psi)$, $$X\hookrightarrow \overline{X}\xrightarrow{\phi} Y\times Z,$$ where $X$ is a dense open in $\overline{X}$, and where $\phi$ is finite. (There is a wonderful discussion of the various forms on pp. 288-289 of Mumford's "The Red Book of Varieties and Schemes".)  The image $\overline{\Gamma}$ of $\phi$ is a closed subvariety of $Y\times Z$.  
Since $f$ is surjective, the projection $$\text{pr}_Y:\overline{\Gamma}\to Y,$$ is surjective.  Since $Z$ is proper, $\text{pr}_Y$ is proper.  By your hypothesis, $\text{pr}_Y$ is generically bijective on points.  In characteristic $0$ (where there is no Frobenius), that is enough to conclude that $\text{pr}_Y$ is birational.  Denote by $U$ the maximal open subset of $Y$ over which $\text{pr}_Y$ has finite fibers.  Since $Y$ is normal, by Zariski's Main Theorem, $U$ is also the maximal open subset of $Y$ over which $\text{pr}_Y$ is an isomorphsm.  The goal is to prove that $U$ equals all of $Y$.  Then the inverse isomorphism composed with projection to $X$ is a morphism $Y\to Z$ (by construction), and that morphism agrees with $\psi'$ setwise.
Okay, the "correct way" to finish the argument is to directly use the Going-Down Theorem to deduce that the morphism from $X$ to $\text{pr}_Y^{-1}(Y)$ is already surjective.  Here is a variation that is a bit more geometric.  Let $y$ be a point of $Y$, and let $F$ be the fiber of $\text{pr}_Y$ over this point. (By the way, another form of Zariski's Main Theorem, the Connectedness Theorem says that the fiber $F$ is connected.)  
By hypothesis, there is a point $(y,z)$ of $F$ that is the image of a point $x$ of $X$.  Let $(y,z')$ be any point of $F$.  Let $C$ be an irreducible curve in $\overline{\Gamma}$ that contains $(y,z')$ and that also contains the image $(y_0,z_0)$ of a point $x_0$ of $X$ that maps into $U$ (this exists by that result in Mumford's "Abelian Varieties" that we discussed before).  Form the image $D$ in $Y$ of the irreducible curve $C$. Define $\widetilde{C}$ to be the closure in $\overline{\Gamma}$ of $\text{pr}_Y^{-1}(D\cap U)$, and then normalize $D$ and $\widetilde{C}$ for good measure.  By construction, $\widetilde{C}$ contains the (normalization of) $C$.  But the image of $\widetilde{C}$ also contains $(y,z)$ by the Going-Down Theorem applied to $X\to Y$. I am using Grothendieck's form of ZMT one more time for the original quasi-finite morphism $f$ to apply the Going-Down Theorem here.  
Finally, since $C$ intersects $\text{pr}_Y^{-1}(U)$, both $\widetilde{C}\cap \text{pr}_Y^{-1}(U)$ and $D\cap U$ are dense opens in $\widetilde{C}$, resp. $D$.  Thus the restriction, $$\text{pr}_Y:\widetilde{C}\to D,$$ is birational.  A birational finite morphism between normal curves is an isomorphism.  In particular, the fiber over $y$ consists of one point.  Therefore, $z$ equals $z'$, i.e., the fiber $F$ is a single point.  So every point $y$ of $Y$ is in $U$.  Technically we did not need to make this argument passing to curves $C$ and $D$, but I find it a more geometric way to understand the commutative algebra.
Counterexample in the Non-Normal Case.  If you drop the hypothesis that $Y$ is normal, there are counterexamples.  Begin with $Y$ a nodal plane curve.  Let $\nu:Z\to Y$ be a normalization.  Let $p$ be one of the two points of $Z$ over the node of $Y$.  Let $X$ be the open complement in $Z$ of $\{p\}$.  Let $f$ be the restriction of $\nu$ to $X$.  Let $\psi:X\to Z$ be the open immersion.  Then $\psi'$ is not a morphism.  
Second Edit: Reduction to the Quasi-Finite Case  I just realized that we can reduce the general case to the quasi-finite case.  For every point $x$ of $X$, choosing an open affine neighborhood of $X$, embedding this in some $\mathbb{P}^N$ and then intersecting with hyperplanes, there exists a locally closed subvariety $V_x \subset X$ that contains $x$ and such that the restriction, $$f:V_x\to Y,$$ is quasi-finite and dominant, and the image contains $y=f(x)$.  Since $Y$ is Noetherian, there will be finitely many such locally closed subvarieties $V_1, \dots , V_r$ such that for the disjoint union $V = V_1\sqcup \dots \sqcup V_r$, the induced morphism to $Y$ is surjective, $$f_V : V \to Y.$$  Now replace $X$ by $V$, replace $f$ by $f_V$, and replace $\psi$ by the restriction of $\psi$ to $V$.  Nothing in the argument above required that $X$ is irreducible.
A: If $f$ is finite surjective and unramified, I think that $\psi'$ is always a morphism. In fact we can prove that $f$ is an effective epimorphism, which means that letting $p_1,p_2:X\times_Y X\to X$ be the projections, any morphism $\psi:X\to Z$ such that $\psi p_1=\psi p_2$ factors uniquely through a morphism $\psi':Y\to Z$. Let us prove that. This is local on $Y$ so we may assume that $Y=Spec(A)$ is affine. Since $f$ is finite, then $X=Spec(B)$ with $B$ finite over $A$. Then being an effective epimorphism is equivalent to exactness of the sequence $A\to B\rightrightarrows B\otimes_A B$, which means that $A\to B$ is injective (this is ok) and that any element $b\in B$ with $b\otimes 1=1\otimes b$ in $B\otimes_A B$ comes from $A$. Now proving exactness of the sequence is étale local on $A$. Due to the étale-local structure of unramified morphisms, we can then assume that $X$ is a disjoint sum of a finite number of closed subvarities of $Y$ covering $Y$. For simplicity let us do the case of two subvarieties. Thus we have two ideals $I,J$ in $A$ such that $B=A/I\times A/J$ and $I\cap J=0$. Let $b=(a_1,a_2)\in B=A/I\times A/J$ have equal images in $B\otimes_A B$. We have $B\otimes_A B=A/I\times A/(I+J)\times A/(I+J)\times A/J$. The condition of equality means that $a_1=a_2$ mod $I+J$, hence $a_1+i=a_2+j$ for some $i\in I$, $j\in J$ and hence $b$ comes from $A$. Thus $f$ is an effective epi.
Finally let us see why this implies what you want. Since $X\to Y$ is unramified, the fibres of the maps $X\times_Y X\rightrightarrows X$ are finite sets of reduced points and checking that $\psi p_1=\psi p_2$ is just set-theoretic i.e. it just means that $\psi$ is constant on the fibres of $f$, which is your assumption.
EDIT (Dec. 31, 2015): as so often, what is left to the reader to check turns out to be 
false. Presently, the computation above works for two subvarieties but 
fails in general for more than two. The point is that if $Y$ is a union 
of $\geq 3$ subvarieties (or better closed subschemes) $X_i$ and if $X$ 
is the disjoint union of them, then the 'glueing' condition on 
$X\times_Y X$ for a map $\psi:X\to Z$ allows only to descend $\psi$ to a map defined on the scheme $Y'$ which is obtained by topological 
glueing of the $X_i$. However $Y'\ne Y$ in general. For example let $Y$ 
be the union of three lines meeting in the origin in affine plane (e.g. 
$x^3-y^3=0$ if base field has char. $\ne 3$). Let $X$ be the 
normalization. Then the glueing condition allows to descend maps 
$\psi:X\to Z$ to $Y'=$ the union of coord. axes in affine 3-space. 
However in order to descend to $Y$ one needs an extra condition which should account for the fact that any 3 nonzero tangent vectors along the 3 
components of $Y$ lie in a common plane. This condition has the 
form of a certain linear relation between the derivatives of $\psi$ at 
the 3 origins of the lines which are the components of $X$. Concretely,
the function which is equal to the coordinate on one of the three lines
of $X$ and $0$ on the other two does not descend to a function on $Y$.
Still, something from the above can be saved to produce examples of
finite unramified effective epimorphisms :


*

*finite unramified morphisms of fibre-degree at most 2;

*normalizations of ordinary singularities. Here I call ordinary
singularity a singularity that local-analytically looks like the union
of spaces $Vect(e_i,i\in I_k)$ in affine $n$-space, for some partition
$\{1\dots n\}=I_1\cup\dots\cup I_d$.
In fact I must say that I am not well aware if there is a well-established
terminology for ordinary singularities. My understanding of this notion
is that such a singularity can be reconstructed from the normalization by
topological glueing, i.e. the normalization should be finite unramified
and an effective epimorphism. But it is likely that experts in singularities will have a more relevant viewpoint.
