On the most basic level: you gain 20 energy every 2 seconds (capping at 100), you have abilities which dump energy (Sinister Strike/Hemorrhage/Backstab) and gain you combo points(which cap at 5). With combo points you use finishing moves (Slice and Dice [attack speed increase], Eviscerate [burst damage], Rupture [bleed], Expose Armor [armor reduction], or Kidney Shot [stun]). You also have opening moves which can only be used from stealth these either do burst damage (Ambush), stun (Cheap Shot), or bleed (Garrote) and generate combo points. You also have many utility spells in Sprint, Vanish, Gouge, Blind, Evasion, Sap, Kick, and Stealth.
vs. Mobs you just do as much damage as quickly as you can (as a swords rogue you Sinister strike, use Slice and Dice spam Sinister Strike and then Eviscerate)
vs. Players you stunlock them while dealing damage (almost always) out of necessity because they die very easily (if a hunter feign death-freezing traps you and then aimed shots you, you are almost instantly dead, if a warlock death coils you, you are dead after the dots are done ticking down, if a Shaman windfury RNGs you, you are dead, if a Warrior overpowers you, you are almost instantly dead, if a Paladin reckbombs you, you are almost instantly dead).
The poison system is pretty simple in PvE you use Instant poison, in PvP its situational but you almost always use Crippling poison
Rogues are different from other melee classes because they are viable in PvE (along with Fury Warriors, and Prot Warriors as tanks) and because of their ability to dictate any PvP encounter while being even or favored in their matchup against every class except Paladin. They also offer variety in that Dagger and Not-Dagger(read swords) rogues are played much differently.
The appeal of rogues is that they're the most viable melee class. In PvE they're the topdog DPS with Fury warriors and in PvP they don't just get kited to death or hard countered.