The Thieves guild is a guild created for thieves who steal anything they require. In Morrowind, it's much easier to be a thief, since any item stolen can be sold to any store. In Oblivion, stolen items are given a red-hand stigma, so regular legitimate shop keepers won't take stolen objects. The same also applies to Skyrim, although a perk can be acquired that allows the player to sell stolen goods to any merchant. Stolen goods in the latter two games may only be sold to fences, special merchants who remove the "Stolen" tag upon purchase.
Though the Guild's actions are illegal, officials in Tamriel have tolerated its existence due to its role as a regulator of crime. The Thieves Guild does not tolerate independent criminals encroaching on their jobs, and have strict regulations of their members: no killing on the job and no stealing from the poor. Due to the nature of the Guild's line of work, they are also exceptional at manipulation and bribery.
Variation Between Games
In TES III: Morrowind
The Morrowind Thieves Guild offers little advantage to the player past what is acquired through miscellaneous quests. Progression is achieved by completing jobs assigned to the player by the Guild's Masterminds and Master Thief. Furthermore, the Guild has a fairly negative disposition with most other organizations, especially the Fighters Guild.
In TES IV: Oblivion
The Thieves Guild in Oblivion is run by the Gray Fox, a mysterious man that nobody has really ever seen before. Many people and officials in Cyrodiil doubt that the Guild even exists.
In TES V: Skyrim
The Thieves Guild in Skyrim is located in Riften. They used to have much influence before membership started declining, and now they are confined to the sewers below Riften, waiting for a chance to return to their former glory.