I'd bet the drain pan was used for antifreeze, or had some other contamination in it before you started the oil change. I've seen the same thing several times.
Best way to check for air bubbles or foaming inside the engine is to quickly pull and observe the dipstick while the engine is running. A TINY amount is somewhat normal; a lot of air bubbles is likely from the crankcase being overfilled.
I see bubbles from time to time when I change my oil. I think it has to do with how fast you drain the oil after it was shut off and how up to temp it was.
Just because oil contains anti foam doesn't mean it won't foam.