The behaviour of a flexible anionic chain of 150 univalent and negatively charged beads connected by a harmonic-like potential with each other in the presence of an equal number of positive and free counterions, is studied in molecular dynamics simulations with Langevin thermostat in a wide range of temperatures. Simulations were carried out for several values of the bending parameter, corresponding to fully flexible polyion, moderately and strongly stiff polyion as well as for the case when bend conformation is preferable to the straight one. We have found that in all cases three regimes can be distinguished, which can be characterized as "random coil", observed at high temperatures; "extended conformation" observed at moderate temperatures (of the order of 1 in reduced units), and compact "globular conformation" attained at low temperatures. While the transition between high-temperature random and extended conformations is gradual, the transition from the extended coil to the globular state, taking place at a temperature of about 0.2 in reduced units, is of abrupt character resembling a phase transition.