Starting in UE 5.3 they added Learning Agents, a plugin that allows you to train agents via reinforcement and imitation learning. See here for more.
Side note: using reinforcement learning for path finding is usually not recommended. Read this Stack Exchange question & answers for more.