"In 1930, Anslinger was appointed to the newly-created FBN (Federal Bureau of Narcotics) as its first Commissioner." Harry J. Anslinger - Wikipedia, the free encyclopedia
He new there was no grounds to prohibit marijuana based on the interstate commerce clause.
He didn't know that. What he knew was that tax stamps worked for firearms (ie., the recently enacted National Firearms Act of 1934), and that they would work for marijuana.
In 1920, Congress enacted the Dangerous Drug Act which made over-the-counter purchase of heroin, opium, morphine and other drugs illegal and deemed that their distribution be federally regulated.
They could have done the same with marijuana.