DER DEN DIE
According to my understanding : DIE ->feminine and also plural we will use DER->masculine we will use DEN -> I"m not getting this exactly Please correct me if I'm wrong ..
You use "den" instead of "der" when a masculine noun is in the accusative case. If you don't know what the accusative case is, I'll explain:
Basically the accusative case (den, die, das) is used whenever there is a direct object, while the nominative case, the case which is usually taught first, is used for the subject (der, die, das).
If you don't know what is a subject (nominative) and what is a direct object (accusative) in a sentence, it's pretty simple. Generally the accusative comes after the verb as the direct object, while nominative comes before the verb as the subject.
In English we have a distinction between the subject and direct object for some pronouns. Here is two examples:
"He knows me."
"I know him."
In those sentences "I" and "He" are the subjects (nominative case in German) and "me" and "him" are their direct object forms (accusative case in German) that we use instead of them. So, for example, we don't say:
"He knows I."
"I know he."
"Him knows I."
"Me knows him." etc.
This is the same as in German except in German instead of just distinguishing direct objects and subjects for a few pronouns they distinguish it in masculine nouns as well.
For example, I'll take the German version of those first two sentences, but I'll replace "He"/"him" with the German word "Mann" instead.
"Der Mann kennt mich"
"Ich kenne den Mann"
Just as you say me/mich instead of I/Ich when a noun is a direct object, you say den instead of der for the same reason.
So, a good tip early on for a beginner like you to easily distinguish the nominative and accusative cases is to take a German sentence like, say:
"Die Frau kennt den Mann"
And with that sentence, take an English translation and replace the nouns with English pronouns, so then you have:
"She (the woman) knows him (the man)"
Because you say "she" instead of "her" in the English sentence, you know why "Die Frau" in the German sentence is nominative, and because you say "him" instead of "he" in the English sentence, you know why "den Mann" is accusative in that sentence.
I personally used this when I was using German and, while it might be the best or most convenient, it worked for me. Keep on making sure to distinguish and recognize which noun is nominative and which noun is accusative and eventually you'll know when to write "der" or "den" naturally, like myself.
Also for the accusative you will say "einen" instead of "ein" for masculine words, you will still use "ein" for neuter words and "eine" for feminine words.
You will also change some of the adjective endings, but that can be complicated so I wouldn't worry about that right now at your level.
There also two other cases, the dative case and the genitive case, but don't worry about those right now. You should probably be comfortable distinguishing the nominative case from the accusative case before you learn the other two cases.
Yes, coffee is masculine (der Kaffee).
Nominative: Der Kaffee schmeckt gut. (The coffee tastes good.)
Genitive: Der Geschmack des Kaffees war gut. (The flavour of the coffee was good.)
Dative: Dem Kaffee füge ich Milch hinzu.
Accusative: Den Kaffee, den ich heute gekauft habe. (The coffee which I have bought today.)