Nothing is absolute, stationary or individual in what is being examined here. Certainly fruits have a mechanism that causes obesity and this is due to the sugars they contain. Specifically, simple sugars cause lipogenesis, increase in triglycerides and increase in fat mass.
However, in the research that has been done, the exact opposite is observed. High consumption of fruit helps to lose weight and maintain a healthy body weight. Thus, it is believed that the mechanisms of fruits that act against obesity (satiety, low calories, intestinal microflora, vitamins, trace elements, phytochemicals, other unknown mechanisms) are more prevalent than the one that cause obesity (simple sugars).
For this reason, if you have not chosen a ketogenic diet, your doctor has not recommended anything different or there is no health reason, you can include in your diet the 5 servings of fruit recommended by every health organization in the world and enjoy the benefits! And since you made the beginning, add the suggested 5 servings of vegetables. The well-known golden rule of 5 + 5 per day!