To me, pilot who’s flying an IFR procedure looks and stays concentrated on his instruments and just keeps a look out if ATC gives him information about conflicting traffic. How can a pilot avoid other aircraft if he’s not looking out and if he doesn’t receive information about potential conflicting traffic? I think that responsibility of the controller could be involved.
In the US, ATC does not provide separation between VFR and IFR aircraft in class D airspace. IFR pilots are supposed to know this. In visual conditions, they MUST see and avoid VFR traffic, that is completely the pilot's responsibility (theoretically).
Practically speaking, the tower will go to great lengths to keep the planes away from each other or at least inform each aircraft about the other's presence, if known.
The same is true in the terminal/enroute environment. I've been flying VFR with flight following and been given an absolute altitude to maintain (higher or lower) to remain clear of an IFR arrival, or even another VFR aircraft. The controller doesn't HAVE to do it, but the paperwork and court hearings would be a major inconvenience when those planes hit as the controller says nothing. I think should should say, "suggest you maintain" instead of "maintain" to remind everyone that ATC isn't providing separation, but I've never heard it done. In NY/NJ here on the east coast, they just tell you to climb or descend and assume you prefer life over death.