Why was cotton chosen to grow on the moon?
China's state-run Xinhua News Agency mentions the reasoning for most of the species they sent:

Why were these species chosen?
Xie [the chief designer of the experiment] said potatoes could be a major source of food for future space travelers. The growth period of Arabidopsis, a small flowering plant related to cabbage and mustard, is short and easy to observe. Yeast could play a role in regulating carbon dioxide and oxygen in the mini biosphere, and the fruit fly would be a consumer of the photosynthesis process.

While this doesn’t mention cotton, it seems very likely to me that, like potatoes, it’s just a very useful crop.
According to another article, the goal for China is a moon research base:

“We’ll use the Chang’e-8 to test certain technologies &amp; do some preliminary exploration for jointly building a research base on the moon,” Wu said.