Aditional to this feature, a new feature in iOS 11 that enables third-party applications to filter incoming messages and sort them into a separate SMS Junk tab that appears in the Messages app when you use an app that lets you filter messages. These applications can use keyword detection or machine learning algorithms to figure out if incoming messages are spam or useful and then sort them accordingly.
Truecaller is now tapping into this new functionality in iOS 11 to enable this feature. Once you update the app, it will guide you how to enable it (Settings > Messages > Unknown & Spam > turn on Truecaller). I’m not quite sure if Truecaller uses simply keyword filtering or machine learning to determine if an incoming message is a spam or not and we will have to use the app further to determine how effective it is at blocking spam and allowing actually useful service messages through.
Update: After a day of use the app is yet to block any spam SMS. YAou are better off installing something that actually works like SMS Shield.