For a non-linear system, machine learning can perform much better and solve more complex tasks. Like walking for a humanoid robot. A linearzied PID solution can not beat that.
For linear systems:
Depends of what you mean with better I guess. My understanding is that you can place some of the poles of a system with a PID pretty much where you want. So for a simple linear system: no.
There exist also other controllers where a LQR can be used in linear systems to get a perfect theoritical controller based upon to minimize the cost of control outputs. (yes, several outputs).
However maybe a ML can be used to choose and tune the controllers better than humans?
EDIT: Also, the discretication is not always perfect (backward or forward euler is common estimates). So maybe ML can help in that too?