Place sweet potatoes on a trivet in your instant pot along with 1 cup of water. Place lid on sealing and set on high manual pressure for 25-30 minutes depending on the size of your potatoes.
Once you can pierce the potatoes with a fork and they are done, remove from instant pot and remove the skin and mash in a large mixing bowl.
Add sugar, salt, cinnamon, nutmeg, butter, eggs, milk, and vanilla to the sweet potatoes and mix until well combined. Pour into a large baking dish and smooth.
Preheat your oven to 350 degrees F.
Prepare the topping by adding the brown sugar, pecans, coconut, flour, and melted butter into a food processor and pulse until you get a coarse crumb. I like leaving a few larger pieces of pecan in my topping.
Sprinkle the topping evenly over the top of the sweet potatoes and bake for 25-30 minutes until the topping is golden brown and the casserole is warmed through.
Store covered at room temperature until ready to serve.