Radio frequency communications operate the same when travelling through a coaxial cable as they do through open-air. They are just shielded from outside interference (called ingress) and leakage (called egress). As such, signals of differing frequencies can co-exist, with each travelling in different directions.
Amplification, however, is a different story. Since amplifiers work in only one direction, the incoming and outgoing signals need to be separated when amplification is necessary. This is performed by a device called a diplex filter, which is sort of like a splitter/combiner that splits/combines based upon the frequency of the signal. In legacy CATV systems, downstream signals were generally about 50 MHz (around the bottom of analog channel 2) and up, while upstream signals were from around 5 MHz to 40 MHz.
An amplifier assembly would (basically) consist of a diplex filter on one end separating the two frequency ranges, followed by an amplifier for each frequency range oriented in opposite directions, and then a second diplex filter to merge the two frequency ranges to its original full spectrum signal.