"This boy is with his friend."
Translation:यह लड़का अपने दोस्त के साथ है।
That's because adjectives change in accordance with the case of the noun they qualify. Here, the noun "dost" is in oblique case, and the adjective "apne" reflects that. (Remember that since the word "dost" ends in a consonant, it takes the same form in both direct and oblique case, whereas "apnaa" (direct) is distinct from "apne" (oblique)).
Let me give you a bit different set of sentences to make things clearer:
मेरा बेटा यहाँ है। - My son is here. (बेटा is direct, and so is मेरा.)
मेरे बेटे का खिलौना यहाँ है। - My son's toy is here. (बेटे is oblique, and so is मेरे.)
Thanks! I guess my confusion is because in another sentence "She eats her apple" they used आपना... Which I guess there it's a direct object instead of the object of a preposition? Sorry, I'm not sure what objective cases take the oblique ending... Thanks for your help!
Sorry for the late response. I wanted to give a proper explanation but didn't get sufficient time, until now. Thanks for bringing up that sentence; the object "her apple" in "She eats her apple" isn't in the oblique case because, as you correctly guessed, it's not an object of a preposition (here, postposition).
Introducing a postposition, however, necessitates using the oblique case.
वह अपना सेब खाती है।
वह अपने सेब को खाती है।
There is a slight difference in the meaning of the two constructions: while the former is used for a general or indefinite object, the latter is used to express definitiveness or emphasize the object and/or the action involving the object. Let me give one more pair of sentences.
(वह) केला यहाँ लाओ। - No postposition -> Object in direct case.
(उस) केले को यहाँ लाओ। - Postposition -> Object in oblique case.
Both of the above sentences mean "Bring the/that banana here", but the second one is referencing a particular banana and/or emphasizing the act of bringing it.
Usually, the postposition is used when the object is a person/people or another animate being(s), and omitted when the object is an inanimate or an abstract object. Omitting the postposition in the animate case can come off as rude, indifferent or just absurd, while using the preposition in the inanimate case may sound excessively pedantic or weird.
I will probably make a post on such usages. It's funny that I didn't notice these nuances before these discussions came up. Let me know if you have more questions.
Thanks for the comments from people who understand what is correct and why. The Duolingo course itself gives zero instruction, and apparently we are supposed to just make wild guesses.
You might already be aware, but if you use duolingo on a computer (not a phone) there are guides for each lesson which break down a lot of these grammar points. I can't fathom why duolingo doesn't provide these on the phone apps, but there you go.
when you click on a lesson to start it you'll see a little menu pop up, and you can click on the little lightbulb icon to open the 'notes' page for that lesson.