Muhammad moved from Mecca to the city of Medina primarily because he and his followers faced persecution by their opponents in Mecca. This migration, known as the Hijra, occurred in 622 CE and was a significant turning point in Islamic history. While Muhammad had established a community of Muslims in Mecca, the growing hostility and persecution from the Quraysh tribe made it increasingly dangerous for him and his followers.
In Medina, however, he found a welcoming environment where he could continue to preach and build a larger Muslim community. This move allowed him to establish a political and social base that would eventually support the spread of Islam. The other options you mentioned, such as not wanting to interfere with existing worship at the Kaaba or being a merchant wanting to trade with the people of Medina, are not the primary reasons for his migration.