The answer is simple but not easy lol. Before I get into it, I just want to say that if you have a persons name, it is BEST to use that name and not anata or the others.
Japanese has a familiarity setting in it's language. It's also intertwined with a ploliteness setting. Anata is "you" in the most basic sense. If you use this with a best friend, it usually means you are a little upset with them or are joking with them. This is also used if you don't have the name of a person. But once you know their name, you should really not be using anata or any of the others with them. This sometimes is used with your spouse or maybe sometimes a sibling.
Kimi is used a lot by men but women can use it too. Kimi is used for someone you are very familiar with and is usually younger than you. Siblings, underclassmen you know well, kids, sometimes the person you are dating. Usually guys can call a girl kimi even if they are not familiar with them. It's "cuter" I guess.
Anta is a shortened form of anata that means "you" but is used when you are very angry with someone. To call someone anta you are calling them something bad. It's almost like a curse word so don't use it regularly. Sometimes people will use this to "flirt fight." Just really steer clear of this one because it is very rude. In fact saying "you" to someone is usually considered rude, especially if you have their name.
Even Japanese people have trouble knowing when and if they should use "you" with someone, unless of course, they just met them and don't know their name. To be safe, always use a persons name if you have it.