"Elephants eat apples."
Translation:Olifanten eten appels.
When both forms are possible, oftentimes it's a matter of style and common practice. In these cases, -en tends to sound more formal/archaic, whereas -s sounds more informal/modern. Sometimes -en also indicates a group of males/with mixed gender, and -s a group of females. For example, I would interpret studenten as either a group of male or mixed-gender students, whereas I would interpret studentes as a group of female students.
A lot of Dutch speakers also tend to drop the final n in -en when speaking, so a word like ziekten might actually be pronounced ziekte—same as the singular. Usually the context makes it pretty obvious it's the plural, but if you want to be explicit, it's more natural to pronounce ziektes. Sometimes -s is less awkward to begin with.
There are plenty of rules/patterns and therefore also exceptions, however. For now, I would say it is safe to stick with -en as much as possible. If Duolingo teaches you to use -s, I suggest you pick up a Dutch dictionary and see if it's the only possible ending. This way you'll slowly build up a feel for it.
You're referring to elephants in general, and not to any elephants in particular.¹ Same as in English:
- Olifanten eten appels → Elephants [in general] eat apples
- De olifanten eten appels → The elephants eat apples
Let me know if that clears things up for you.
¹ This is why de/het (= the) are called the definite articles, because they refer to a clearly defined thing/group of things. In this case that'd be a specific group of elephants.