Paying attention is being more attentive, being more focused, etc.
Ex. "Did you pay attention to what you're teacher said ? "
Taking caution is exactly like paying attention, but used mostly to avoid some mistakes and danger. So basically you being more attentive in order to avoid certain mistakes or some danger. In other words, it is used in situation when the speaker is doing everything in order to avoid some danger or mistake.
Ex. "He approached the lion with caution (with extra care) "