Why first (and only first) iMacs were colored with red, blue, etc? And why Apple didn't continue to create iMacs of different color?
The original iMac was announced in May 1998 (shipping in August of the same year) and was positioned as a low-end, consumer-grade, internet-oriented model. The colour was Bondi Blue. Apple marketed the model as being the most original new computer since the original Mac of 1984.

The graphic in your question was from the so-called '5 Flavors' models announced in January 1999. These models featured a 333 MHz CPU speed, with all other specs being the same as the original iMac.

The colours changed, but the styling remained the same until the flat-panel models were introduced in January 2002. The flat-panel iMac was intended to be a more sophisticated product and that air of sophistication has stayed with the iMac image to this day.