I guess "the apple" here refers to apples in general, a common construction in many languages, if a bit un-natural in English. This is not talking about one specific apple is it?
Why the word changed if it's at the beginning or in the middle or end of a sentence? “Jeg spiser et epple?” “Eplet er en frukt?” How must I know how and when to change it? Thanks in advance!