When is $f$ not the coequalizer of its kernel pair? Let $f : X \rightarrow Y$ be an arrow, and suppose it has a kernel pair $p_1, p_2 : P \rightarrow X$. I know that in general, $f$ may not be the coequalizer of $p_1, p_2$, but what is a simple example of such a case?
 A: As Zhen Lin noted in the comments, coequalizers are always epimorphisms. So, when $f$ is not an epimorphism, it will never be the coequalizer of its kernel pair.
For a concrete example, in the category of sets, epimorphisms coincide with surjective functions, so any non-surjective function will do.
A: The simplest example is the category with two distinct objects $X$ and $Y$, and a one non-identity morphism $f\colon X\to Y$. The coequalizer of its kernel pair is the identity morphism on $X$. Note that $f\colon X\to Y$ is an epimorphism.
More generally, $f\colon X\to Y$ is a monomorphism, and a morphism is a monomorphism if and only if it has a kernel pair whose projection morphisms are equal. In particular, the coequalizers of the kernel pair of a monomorphism are isomorphisms. Thus any epimorphism that is a monomorphism without being an isomorphism has a kernel pair but is not its coequalizer.
Thus examples of such epimorphisms include $\mathbb Z\to\mathbb Q$ in the category of rings (or more generally monic localizations), as well as continuous identity functions in the category of topological spaces from a finer to a coarser topology on a set.
