My understanding is "you're not you" means "you're not yourself", while "that's not you" is something I would use for example if we were looking at a photo. Is that right? Can you explain why "that" changes the meaning of the sentence? Is it because "that" is a "demonstrative pronoun"? What other situations would you use the one or the other?
They are quite different.
"That is not you" is a straightforward grammatical form. "That" can be something you are looking at e.g. a photo, or a reference to some characteristic. If I say "I think I'll take a course in homeopathy" my wife, would probably say "That's not you".
"You're not you" is an idiomatic way of telling a person that they are behaving out of character, or that they look ill. But perhaps more common, and closely related is "you don't seem yourself". Or indeed a person might say "I don't feel myself", usually meaning that they don't feel well.