So you have this idea for a genre or you've written a story and are ready to sell it. Now what?
Well, you need to know what genre the story belongs in. Why? Because knowing which genre a story belongs to can help you sell it because publishers (and readers) use these classifications to make some assumptions about the story. For example, in a science fiction story I can expect to see alien races or plausible future speculated. Depending on the type of science fiction, the writer may adhere to science facts as much as possible with only a slight deviation, such as faster-than-light spaceships, or they may use many of the accepted conventions in the genre to create a story that is both interesting and enjoyable.
Orson Scott Card makes are great point in his book on writing speculative fiction that genres are more for bookseller and publisher and less for you. Nevertheless, you should have a rough idea which genre best describes your story if only so you can identify your audience (always a good starting point when writing anything). And knowing the genre helps me to know what conventions I can alter. For example, if the audience is expecting aliens maybe I write a first contact story. Or if they expect faster-than-light spaceships, maybe I restrict the technology to star gates only.
I'd love to give you a list of genres but alas they are subjective and I have not found one that is inclusive enough to satisfy me. Suffice to say that fantasy, horror, science fiction, romance, historical fiction, and mystery are the main categories, although I'm sure others would amend and modify this list.
But here's the good news, unless you are trying to write serious literature that will stand the test of time like Joyce or Faulkner or Hemingway, your story will probably fall into one of the genres I listed. And generally speaking, you will not have to explicitly pick a genre. Your story will do that for you.
But here's the bad news, sub-genres make the whole process of determining a genre a little like order coffee at Starbucks. In my case, for example, is my fantasy novel, an epic or traditional or swords and sorcery or something else? It is clearly not contemporary or urban fantasy, but it could be light fantasy depending on how you define these terms.
Personally, I think of my novel as an epic fantasy because it will span eight books and the result changes the world in which the characters live. In that sense it is no different that many of the epic fantasy novels I've read. Frankly, so long as you know the main class your story belongs in you should be okay. Don't worry about the sub-genres unless you are submitting a short story to a magazine. And then look for the magazine to define their terms.