Inspired by recent discussions among my online friends and acquaintances, I thought I should examine this question. It's a surprisingly thorny one.
Looking at computer role-playing games, there are multiple definitions accepted by people. Some will argue that the defining feature is player agency; if the player's actions can affect the world, it's a role-playing game. Some say it's character progression; if the character becomes more effective intrinsically, then it's a role-playing game. Some say it's down to whether success is determined by player skill or character skill. All of these have some justification, but really, we have to look at the origin of role-playing games to think about this meaningfully.
And that means Dungeons and Dragons. D&D is generally considered the first RPG, and we can reasonably look at it to help us define what makes an RPG an RPG. So, what's distinctive about D&D? One of the big things is character progression. In D&D, that's handled with character levels, but characters becoming more effective doesn't necessarily mean levels; it can be handled with skill points, or any other method of making a character better at doing things. But why does D&D have levels? Well, D&D began as a rules hack for a tactical wargame. The original D&D booklets didn't have combat rules as such; they recommended you use the Chainmail rules D&D had grown out of. The levels came about as a second-level D&D character was assumed to be as effective as two first-level characters. He was essentially worth two men, and so many of his effectiveness factors simply doubled. This isn't exactly fine-grained, though, and later systems used a more gradual advancement mechanic. So character advancement is a part of the RPG nature, but character advancement is present in Grand Theft Auto, and that's not an RPG franchise.
Another distinctive point for D&D is player agency. Because the game is moderated by a person, the world can be changed by a sufficiently determined player. Many campaigns have that as their goal, insofar as "killing the Great Foozle" counts as changing the world. The key point here, though, is that the world can have multiple possible results, and which one happens depends on the player's decisions. This is quite common on a small scale in many games considered RPGs; Fallout has multiple possible resolutions to each quest, which feed into an overall state for each area, and the narration at the end of the game changes depending on how you affected each area.
The third big point is character skill versus player skill. The problem with this is that creating a suitably skilled character becomes a game in itself, and character skill is thus ultimately determined by player skill. Some games also combine the two; Oblivion, Fallout 3, and later games in their series have lockpicking as a skill the character has, and also as a mini-game which the player is forced to endure. To the best of my knowledge, Oblivion's lockpicking skill has no use beyond "walling off" higher difficulty locks from players with insufficient skill; the minigame is just as frustratingly difficult no matter what, thanks to imprecise controls, input lag, ridiculously tight timing windows, and draconian punishment for failure. Fortunately, things were much improved for Fallout 3; character skill increasing still served as a skill gate of sorts, but a character with high lockpicking skill made the minigame easier for a human to complete, and the controls were massively improved by removing the timing puzzle element.
The overall answer to what makes an RPG is one that I refuse to give you; games are a continuum, and there is no real hard line dividing RPG from non-RPG. The factors I consider most important are character advancement, player agency, and significance of character skill. If they're present, in reasonable proportion, I'll consider the game a role-playing game. This means that I consider the Deus Ex series to be RPGs; character skills have significant effects on what the player can achieve, there is character advancement, and player choices affect the game world.
Ultimately, you'll have to make your own decision; or, you could just take my approach. Games are in one of four categories, based on two factors: whether I've played the game, and whether I enjoyed it. Obviously, in the case of games I haven't played, that becomes "whether or not I consider it likely I'll enjoy it".