Firstly, it is ok to gain some extra kgs of weight during pregnancy; it is a natural process and that is how it should be. A woman gains around 12 – 15 kgs over 9 months of her pregnancy (Read https://nuvovivo.com/blog/pregnancy-and-weight-gain)
Before rushing into a weight loss routine immediately after pregnancy, it is very important to know that, weight loss has to be gradual and slow. A sudden/huge calorie deficit an weight loss can be detrimental not just to the mother, but even for the baby.
The baby gets the milk from the mother and hence the mother has to have an additional 300 – 400 calories than the usual calorie deficit followed by a lady who is not lactating / breast-feeding. It is highly important to follow a balanced diet and not get into any fad diet such as keto, paleo etc. High protein/fat can create constipation, bloating and gasy feeling (flatulence) for the kid also. The mother’s milk will be affected by her eating patterns and remember that the newborn is not accustomed to such drastic change in the types of macronutrients (fat, protein, carbs)
The muscle group that goes through a drastic change during pregnancy is the Core Muscles (Read https://nuvovivo.com/blog/core-workouts/) These muscles (core, hips, and glutes) usually become weak and may even change the form slightly. It is important to not immediately perform highly strenuous exercise, rather, a series of core strengthening exercises are good to start with.
Here is a series of core exercises, the mother can do after 4-6 months