You need to initialize the collection before using it.
If you import the “Workflow Manager Activities” package, by Microsoft, you get some neat activities one of which is “Build Collection”. Simply drop this activity onto your work area before using the collection and you will be prompted to provide a type. You can also use the ctrl+k shortcut to create the variable which will match the type you selected when you drop in the activity.