Although, Julius has answered it pretty well and it is correct, I'd like to add words from director here.
As Joe Russo explains why Captain Marvel didn't put on the Infinity Gauntlet,
Q: Why Iron Man has to be the one to do the final snap, couldn’t the people like Thor, Star-Lord or Captain Marvel whom all previously have handled the power of Infinity Stones done it instead?
A: Thor in this movie couldn’t do it, only Hulk was strong enough to do the snap without dying. We are still not sure whether Captain Marvel can also withstand all the power of Infinity Stones at once. The reason we choose to let Iron Man do it in the end was because he was the closest one to Thanos at the time. In all the futures Doctor Strange foresee, Iron Man was the only one who could get close to Thanos and do the snap. People usually think the death of a hero is a horrible tragedy. But we think this is different. When his death was able to bring back hope, to save half of the universe, then his death was powerful and meaningful. We shouldn’t feel too sad or angry about it.
So, they only let Iron Man do it because Iron Man was close to Thanos and can do the snap as foreseen by Doctor Strange.