While you can make glazed carrots in an electric pressure cooker, this recipe as written won't work - you need to add water to essentially steam cook the carrots, which would dilute the glaze. It's not as hands-off, but to get around this, you can use a steamer basket inside the Instant Pot, placing your cut carrots (or baby carrots) and chopped onions in the basket with 1 cup of water in the pot underneath. Cook on High pressure for 2 minutes and do a quick release and remove the vegetables to a large bowl and drain the liquid from the pot. Turn the IP to sauté and add the remaining ingredients, stirring until butter is melted and everything is combined, 1-2 minutes. Add the carrots and onions back to the Instant Pot and stir everything together, keeping on warm until you need to serve them.