How does an XOR phase difference detector behave when input frequencies are different?
When the two inputs to an XOR phase detector are at different frequencies, it behaves as a frequency mixer, with a nominally zero mean output.
It's only when the two inputs are the same frequency that you can meaningfully talk about a phase difference for them. The XOR then has a non-zero output which represents the phase difference of the two signals, at least over a half cycle.
Fortunately for PLL designers, the output when the input frequencies are different is not useless. Fed back into the PLL, the varying output of the XOR causes a frequency modulation of the VCO, which modulates the XOR output frequency. This FM causes the mean XOR output to move slightly away from zero, which will alter the mean VCO frequency via the PLL. As long as the output frequency of the XOR is less than the loop bandwidth of the PLL, each successive cycle of frequency modulation will nudge the VCO frequency towards the reference frequency. The effect is small, but if the loop has the range, it will eventually capture under these conditions. Often, the users of the loop are impatient for speed, and so other faster methods will be used to obtain lock, but if time is not of the essence, an XOR can be used by itself to lock a PLL.