I have the same issue. The flaps do not move visually on the default C172 in MSFS 2024. However my Turtle Beach Yoke shows that the flaps are getting extended/retracted. I am not completely sure that the flaps affect the plane. It might just be a problem with the animation.
I have just seen the problem on PC, but I also think I saw it on XBox Series X.