where was this developed?
At Harvard College Observatory
Main sequence
Annie Jump Cannon and Edward C. Pickering at Harvard College Observatory developed a method of categorization that became known as the Harvard Classification Scheme, published in the "Harvard Annals" in 1901.
how do you know if a star is main sequence By the color-magnitude plots of stellar color versus brightness. how is it formed? After condensation and ignition of a star, it generates thermal energy in its dense core region through nuclear fusion of hydrogen into helium. are they categorized? Yes, the  spectra of stars showed distinctive features, which allowed them to be categorized. how is it done? Through the Harvard Classification Scheme.
wiki:25677730
Main sequence [SEP] History
In the early part of the 20th century, information about the types and distances of stars became more readily available. The spectra of stars were shown to have distinctive features, which allowed them to be categorized. Annie Jump Cannon and Edward C. Pickering at Harvard College Observatory developed a method of categorization that became known as the Harvard Classification Scheme, published in the "Harvard Annals" in 1901. In Potsdam in 1906, the Danish astronomer Ejnar Hertzsprung noticed that the reddest stars—classified as K and M in the Harvard scheme—could be divided into two distinct groups. These stars are either much brighter than the Sun, or much fainter.