Activating the quest
Open the world map and you will note that Riften is in the south-east part of Skyrim (screen above). If you have already visited that area, it of course would be best to use fast travel. Otherwise, you will have to plan your journey there. The easier solution is using the carriage, for example the one stationed in Whiterun Stable. If you want to reach Riften on your own, it would be best to start at Ivarstead, heading east and making use of the road signs on your way.
Regardless of the chosen method, you need to approach the city from the northern side (screen above). During the first attempt of entering Riften you will be stopped by the Riften Guard. You can either pay the fee for accessing the city or use Speech to convince the guard to your rights or intimidate him. Afterwards, head to the big gate to enter the city.
The characters which can lead you to the Thieves Guild can be found either at The Bee and Barb (at night) or on the marketplace (during daytime). Brynjolf should approach you after you get nearby him. The man will ask you for a favour. You will have to steal a ring belonging to Medasi and afterwards slip it into the pocket of the merchant Brand-Shei.
Thieves Guild quest unlocked: A Chance Arrangement
New main objective: Meet Brynjolf during daytime
Head out of The Bee and Barb and stay at the Riften main square. In accordance with the information Brynjolf gave you, you can meet him here only during daytime, i.e. between 8 a.m. and 8 p.m. If the hour isn't right, you can use any bed or just wait until morning comes. In the latter case, press T and choose how many time should pass. Find Brynjolf (screen above) and initiate a conversation to begin the whole action. He should call the other traders to him, thanks to which you will be able to begin.
New main objective: Steal Madesi's Ring
Approach Madesi's stand and stand by the sliding door. Make sure you have at least a couple lockpicks and crouch. You need to make sure that you're hidden (screen above) and the eye icon doesn't appear, as otherwise you would get noticed by a guard at once. Additionally take a look around to check if any of the guards is heading this way. Items and skills boosting the Sneak skill might come in handy here, though it won't be necessary as you will be able to complete this mission even by playing with a character without experience in pickpocketing. Use the lockpick to open the lock in the door.
Additional note - If you get caught red-handed during this quest, you will traditionally have to choose if you want to pay the fine, go to prison or try to defeat the Riften Guards in direct combat.
It's not the end though, as now you will have to break into Madesi's chest. Just like before, make sure that you're hidden before making any attempts (screen above), thanks to which you won't get caught stealing. Use the picklock to open the chest and take all the items, especially Madesi's Ring.
New main objective: Plant Madesi's Ring
Return to where Brynjolf is giving a speech and stand in the spot presented on the screen above, i.e. behind Brand-Shei's back. Crouch and once again make sure that you're hidden (the game should inform you about that, instead of showing an icon of an eye). Press E to open the pickpocket menu.
Go to your own inventory, choose Apparel, mark the recently gained Madesi's Ring (screen above) and press R to put it into the pocket of the trader that you interacted with. You can close the window afterwards.
New main objective: Speak to Brynjolf
Return to Brynjolf. If you managed to steal and plant the ring, you will be rewarded with gold. If you got caught in the process, he will only tell you that he's disappointed by your actions. Brynjolf will have more work for you, even if you failed the first time.
Thieves Guild quest unlocked: Taking Care of Business