Since
@List is scoped within Process, it will be destroyed when Process exits (unless you do something with the "return value" of Process, which will be the right-hand-side of your last assignment: a single FormData item), which will destroy every element of the array in the process. Perl keeps its own reference count of each variable, even if it's nested within another. When FormData exits,
$UserData is destroyed, but the data it was pointing to gets allocated into a
@List element, so the reference count goes from 1 to 2 to 1 (or maybe just 1 -> 1; I'm no expert). When your first function terminates,
@List is destroyed, dropping the reference counts for each of its elements to 0, causing them to be reaped in turn as well.
Remember that resources aren't literally free()'d, they're just returned to the pool for other Perl variables to use as needed. You cannot "release" memory consumed by now-unused variables back to the OS. See How can I free an array or hash so my program shrinks?.