How to specify ILM policies in Elastic agent policy config?

Thank you @leandrojmp . Your response is very concise and accurate.

I have a related post about elastic agent datasets: Performance impact of setting 'namespace' in Elastic agent policy config

If I have 2000 Elastic agents, 20 agent policies, does that mean that:

  1. Look up the Elastic agents that I want to have a customized data retention policy
  2. For each Elastic agent, I need to look up the datastream used by that agent going to kbn:/app/fleet/data-streams
  3. For each datastream that I want to have a customized ILM, I would need to use custom ILM policies according to the documentation

Is my understanding correct?