Hi. Ketosis is the state in which your body burns ketones instead of glucose for fuel.
Normally carbs supply glucose and insulin is produced by your body when it detects glucose so that the glucose can cross cell membranes and enter the system. Unfortunately, excessive carbs can lead to excess insulin and your body becomes insulin resistant, which is the start of T2D. One of the functions of insulin is to store fat, so this is a direct side effect.
An alternative, which was common in the diet in pre-modern times, was to eat more meat and fat (especially) rather than carbs. Without carbs your body produces ketones as fuel as a direct replacement for glucose, ie ketosis replaces glycolysis.
Ketosis is a natural state and not to be confused with ketoacidosis, which is a serious condition in T1D when the ketones are an order of magnitude higher.
Generally to achieve ketosis, you should eat less than 20g of carbs/day. You should also eat moderate protein, about 0.8g/kg of body weight. The rest of your diet is fat and you can eat what you like as fat is filling and you will reach satiety before you exceed any calorie limit.