Difference between integrations and Platform: (Yaml)

Can someone explain what the difference is between integrations within settings menu and configure it via platform: in the yaml file?

For example i have a unifi controller and can be connected in both ways, and if there is none how can I set extra variables within the integration (menu) option like track_new_devices?

Does anyone know what the difference is?