@ice_cream If you have multiple lists need to be created based on the multiple conditions then it would be better to go for switch case instead of if. Use the below link for writing a condition for switch case
Also, you can create different lists for each condition you have but those has to be defined in prior.Use the below link