There comes a time in every author's life when someone somewhere is going to say, "Hey! My third cousin six times removed just finished a book. Will you talk to her?" When that happens, if the author in question agrees to the chat, genre is likely to be one of the first points of discussion. Why? Marketing, my friend. You have to know which round hole you intend to pound the square peg of your book into. Only partially kidding on that last bit. If those of us writing intend to sell anything to anyone, we'd better be prepared to describe what we've written. Genre is the generally the broadest description - beyond 'book' - that we're likely going to get away with using. You have to know your genre before you agent shop, before you can query a publishing house or an editor.
I'm not sure what quirk of the brain is exposed by the human impulse to label things, but we, as a species, do seem hung up on parsing, sorting and neatly stacking our piles of stuff. Maybe the whole human genome is a tad OCD. Whatever, we're most comfortable being able to point at a thing and saying, "That's a vladesimus tangential thingamajigie!" And if the human race is a little OCD, the publishing world is far and away more so. We all know authors who's books got to marketing before being sent back with a note that says, "We don't know what to do with this." "But it's a vladesimus tangential thingamajigie!" the author whines. Sure, and the marketing department only has a slot for vladesimus tangential thingamajigies with pie. Genre matters.
The moral of that paragraph being: When authors start mashing genres together looking for the secrets of cold fusion and hoping to ignite a tiny gleaming star in the eyes of reader everywhere, it has to happen with the awareness that the whole unstable project could detonate instead of meshing into something brilliant and stable. Let's contemplate the mental image of smoking, irradiated messiness for a moment. I have a few of those. They still glow in the darkness under the bed, hauting me in the night. Sad. Thing is. Sometimes, it works. Sometimes, it works so well that the mash-up of genres becomes a genre unto itself. Paranormal Romance. Scifi Romance. Medical Mystery. (That last included to prove it's not just the romance market that's willing to spawn genres.)
It's a razor's edge to walk, writing something that defies genre - especially if you aspire to sell into a publishing industry that's super invested in slotting stories quickly and easily. If you're self-publishing, the final arbiters of genre are your readers. So classification of your story is between you and them. Just remember, if you write it, you have to tag it so your readers can find it.
If you ask me about crossing genres, I have to tell you to go for it. My first two books were Scifi Romance. Then I had to add a bit of the erotic to that because, you know, mixing two genres wasn't enough. Don't worry about what's selling or not. Read. Write. Have fun. Stay true to your story your way for at least one draft. If you're writing what you'd want to read, genre will likely take care of itself. When your draft is completed, you may find your book already falls handily into a publishing box. But if not, that aspect can be tweaked on rewrite.
Maybe the trick really is writing what you wish you could read. Please do. I know how much I love it when I get to read a book I wish I had written. Also? Vladesimus Tangential Thingamajigie. My new band name. You know. For when I learn to play something that would be acceptable to a band.