Using aluminum foil on a non-stick pan is not recommended. Non-stick pans have a special coating that can be damaged by the use of aluminum foil or other abrasive materials. Scratches or cuts in the non-stick coating can reduce its effectiveness and potentially release harmful chemicals into your food.
If you need to cover your food while cooking in a non-stick pan, it's better to use a lid or another suitable heat-resistant cover specifically designed for cooking. This will help retain heat and moisture without risking damage to the non-stick surface.
If you want to use aluminum foil for cooking, it's best to use it in a pan or dish that is suitable for direct contact with aluminum. Examples include baking sheets, roasting pans, or aluminum foil pans designed for cooking purposes.