As a followup to this question, I was wondering, will my work still be considered a spy novel even if it doesn't take place in a contemporary setting? Although I write as a hobby, I was wondering if I my work were published, what would it be the genre? A science-fiction spy thriller? Spy fantasy? It's set in an alternate universe and on a different planet, and my main character is given the task of creating and running a spy network in a hostile territory. My novel contains elements of the spy genre (dead drops, developing assets, double agents, eavesdropping, etc..), only without the black ops assassin being sent to take out a target. The information gathered is being used for political gain and to ensure the security of my main character's home country. A quick search reveals that quite a few novels exist that have spy/fantasy/science-fiction/supernatural elements. As long as the term spy is in the genre, I'll he happy.
Why is genre so important to you? Personally I would just write what you want to write. Deatils like that will sort themselves out once you're finished and you're going through the process of getting published.
I just want to know if what I'm writing would be seen as a spy novel by my readers. It's a comforting thought , and it's what gives me motivation to write.
Well in that case it would be spy-ience fiction Puns aside, I think it would traditionally go on the science fiction / fantasy shelf; those genres are very accepting of other formulas. Mistborn: The Final Empire for example is a heist novel guised as a Fantasy. SFF is probably the audience that would find a non-Earth spy novel most appealing too. The Clancy crowd wants to read about Earth geopolitics.
Agent of Byzantium by Harry Turtledove is a spy novel set in a 14th century Byzantium in which Muhammad became a Christian saint rather than receiving his Message from Allah. The primary antagonist is the spymaster (spymistress? it's been a while) of the Zoroastrian Persian Empire, and it gets pretty James Bond at points IIRC. Spoiler: Alternate version of Muhammad's message In the book, St. Muhammad's prayer is mentioned several times. "There is no God but God, and Jesus is his son" rather than the version we know now "There is no god but Allah, and Muhammad is his messenger." With the energy of the Arab peoples put behind Christianity, history would have turned out very differently.
Poul Anderson wrote several novels about a James Bond type character in the 31st century - Dominic Flandry. Very entertaining books. They were classed as science fiction.
I've read several sci-fi novels and short stories that were genre crossovers. Steve Perry wrote a noir detective short set on a space station that involved a guy who did molecular sculpting of "ship in a bottle" models that could only be seen with powerful microscopes. The setting is only the clothes; the story is the person underneath.
I see that OP is 119 years old and hasn't been around for a while. Here's hoping she survived the covid being in that high risk age group.