This question can be answered in two ways.
First, when it comes to setting from a temporal point of view, the story takes place during the time of the decline of Napoleon's empire. More precisely, the story starts in 1815 and it ends in 1844.
Second, when it comes to location, the story mostly takes place in Paris. Most of the major events of the book are in Paris, which make sense because the Count of Monte Cristo (Edmond) is reintroduced into society as a wealthy nobleman.
Other places are also important. Marseilles is where Edmond is from. This is his hometown, where his father was and died as well as where he fell in love with Mercedes. This is also where he was framed.
Rome, Greece, and Constantinople also play important roles. For example, Edmond emerged in Rome after nearly a decade (after his escape) and makes friends with Albert de Morcerf, who in turn introduced him to Parisian society.