Most phones come with built-in security measures to combat viruses and malware and therefore a third-party app is not necessary. However, there are  steps you can take to protect yourself from a malware attack from occurring, such as:
Only downloading apps from the Google Play Store or the Apple App Store
Keeping your operating system up to date
Not clicking on links or hyperlinks if you are unsure of their source
Not rooting or jailbreaking your phone
Keeping your Smart Manager enabled on Androids
Backing up your phone data regularly
Not making any sensitive transactions on public WiFi