More likely that the guy(s) who wrote Genesis didn’t know that heavier elements come from stars, hence stars before planets.
more likely, that knowledge isn’t pertinent, as God could/did create the universe as is, heavy elements and all.