Why do we need to know why something is needed or relevant?
The term I think of that is most associated with this concept is salience.
There is a massively informative world out there. If you were to spend all your time focusing your attention on arbitrary objects or sensations from the environment you would never get anywhere. You might die of starvation or some other unmet physiological need or get eaten by a tiger while focused on something that isn't dangerous and doesn't help you reproduce - this circumstance is not evolutionarily favorable.
Though salience is often focused on more immediate threats and benefits, more complex organisms including humans are able to plan ahead a bit and put effort into things now that have benefits in the future. Some things seem to be innately salient, others become salient with learning.