You can "use" a 12AT7 to replace a 12AX7, in that the pin connections of the two tube types are identical, but that would be far from ideal. The 12AT7 has less gain, a lower plate resistance, and a higher transconductance compared to a 12AX7. In a phono stage, the difference in gain would be quite noticeable, even with high output cartridges, if one were to replace a 12AX7 at the phono input with a 12AT7. But also the 12AT7 would function suboptimally in a circuit designed for a 12AX7, so there might also be noticeable distortion. (I am qualifying my statements, because I know someone is going to claim that he used a 12AT7 in this fashion and it sounded wonderful.)
Mulveling mentions encountering 6SN7s where one triode tests like new and the other triode tests like its near death. (The 6SN7 is a dual triode, with two completely independent triodes in a single glass envelope.) This can happen with a tube that has been pulled from a piece of equipment where only one of the two triodes (the dead one) was actually attached to the circuit. Often equipment was built this way so that one could swap L and R channel tubes after the tubes seemed to need replacing, and thereby gain use of the unused section in the opposite channel.
I am not a big believer in paying a premium for matched tubes, because tubes do not age in synchrony. So after a few months of use, one of those two tubes may test quite differently from the other.