Can I use a nonstick pan or a stainless steel pan to bake a cake in a microwave?
No, but you can cook in microwave safe cups or basically anything that is microwave safe. If you don't have anything big enough to cook a cake do you maybe have a large based jug?
NO. Do not use metal in the microwave. It will spark due to the charged particles that start going crazy in the metal. General rule just like mom and dad said ... Don't do it.
Get a ceramic bake pan.
And remember microwave safe plastic does not mean food safe. Cooking in plastic is bad. Microwave safe means the plastic wont melt.... not that the plastic wont transfer chemicals into food.
Hope that helps.