The article ein has to be inflected according to the grammatical gender and case of the noun: http://en.wiktionary.org/wiki/ein#Declension_2
You use einen in the accusative case for masculine nouns and einem for dative case and masculine or neuter nouns.
„Ich habe einen Hund.“ – „I have a dog.“
„Ich gebe das Futter einem Hund.“ – „I give the food to a dog.“
EDIT: corrected an error regarding the inflections. Thanks to the fellow Duolinguists for pointing out the mistake.
I am only a beginner but I think there is a small mistake in your answer; "einen" in the accusative case is only for masculine and not also for neuter nouns.
Ich habe einen Hund (M) (I have a dog)
Ich habe ein Pferd (N) (I have a horse)
Can please a German native correct me if I am wrong?
I guess a comment here might not be enough to cover the grammatical cases of the German language, so I suggest you to read about their usage, for example here: http://german.about.com/library/blcase_sum.htm
BTW: Depending on your mother tongue your disadvantage might not be as big as you might expect. For example there is no dative case in English, either. I guess it all comes down to how easy it is to comprehend articles about the language's grammar. :-)
Wow, this article is about 9 pages long. I think I might need to quit Duolingo for a while just to read and completely understand it all :)
My mother tongue is Hebrew. Yeah... even I don't know what cases exist in that language. But I do hope the German grammar and I will get along eventually. Thanks for everything :)