We can pretend we know what we mean when talking about different genres, but no one knows what they are precisely, only that they exist. In a bookshop, readers are drawn to certain shelves, and steer clear of others (some they’ve never tried!) because there exists, in their life, a feeling they need more of.
They know which book to pick because they’ve learned, from similar books, what to expect.
Take science-fiction. A sci-fi novel can have spaceships, time travel, androids, space exploration, and aliens, but ultimately, its purpose is to make the reader feel a sense of wonder. That feeling, not spaceships, is central to the genre.
Fantasy can have kingdoms at war, systems of magic, ancient mysteries, elves, dwarves, and thieves, but ultimately its purpose is to make the reader believe in magic, at least for a while longer.
For some genres you need look no further than the name of the genre you’re writing (Romance, Thriller, Adventure, Mystery, Erotica, Horror), for others you may need to scratch your head a little (Crime Fiction, Literary Novel), but your success as a writer depends on how well you elicit the emotion your readers are looking for.