#Yes, your GM can deny your Character
Take a look at your PHB:
Your DM might offer additional backgrounds beyond the ones included in chapter 4, and might be willing to work with you to craft a background that's a more precise fit for your character concept.(PHB 5e, p. 13) p13
Talk to your fellow players and your DM to decide whether your characters know one another, how they met, and what sorts of quests the group might undertake.(PHB 5e, p. 15) p15
This is what the Player Handbook tells you: you shall talk to your GM how your character ties into the campaign, and they tell you what is ok or what you should adjust. Note, that they talk about complete characters on page 15, and without a background (page 13!) you have no complete character. Without an allowed background, you are not ready to play.
The GM is entitled to do so because of the Dungeon Master's Guide:
As a referee, the DM acts as a mediator between the rules and the players. [...] Sometimes mediating the rules means setting limits. (DMG 5e, p.5) p5
The GM is the final arbitrator. They are there to set the rules and rulings of the game at the table, and the printed rules make the GM's word and decision higher than the printed rules. But to deny a character doesn't even need to crack out this whip but they can point to a different, equally binding rule that allows them to deny your character:
If they decide on campaign rules, those are binding. And these campaign rules include — so I read it from your description — that evil characters are not allowed for some reason. To set up such rules/restrictions is suggested by the DMG (emphasis mine). It clearly says that they are not only allowed but expected to set character generation rules as they see fit.
As you start to develop your campaign, you'll need to fill in the players on the basics. [...]:
- Any restrictions or new options for character creation, such as new or prohibited races. (DMG 5e, p.26) p26
Since their ruling is binding, you have to oblige.
#What about AL?
Adventurers League allows Evil only as "Lawful Evil", so unless you are LE, your DM is even forced to deny your character in AL. But they only may accept your LE character if it conforms to all the AL rules - which disallows you to have the Background you want.
But this only concerns Adventurers League games under AL rules.
#A way out?
Of course, you may leave or argue with them. Or you are constructive and try to get your DM to adjust the background to fit their campaign. Talk to them. Ask what you need to adjust. Indeed, the DMG tells the DM to talk back to you to adjust your character if needed.
Suggest alterations to a character's story so it better fits your world, or weave the first threads of your campaign into that story. (DMG 5e, p. 26) p26