"The children love you."
Translation:Barnen älskar dig.
Dig (pronounced like dej, which is why people spell it that way in really casual contexts) is what we call an object pronoun, while du is what we call a subject pronoun. It's like the difference between I and me or he and him in English, the only difference is that the object form of you in English is still you while the object forms of du and ni are dig and er.
Jag tycker om honom.
I like him.
Du är trevlig. Jag tycker om dig.
You are nice. I like you.
Ni är trevliga. Jag tycker om er.
You guys are nice. I like you.
More information here:
It has to do with subject and object. That means that it has to do with whether the person is acting (subject) or acted upon (object). For the English pronoun "you", these forms are the same.
I love them - Here "I" is the subject and "them" is the object.
They love me - Here "they" is the subject and "me" is the object
This is the difference with du and dig respectively. If you refer to the person acting, it's "du". But if you're referring to the person acted upon, it's "dig".
Does that make it clearer?