You need to create an Event Handler on the dataflow.
The type of this event handler depends on what you want to do, but OnPostExecute or OnPreExecute seems a good choice.
Inside this event handler, you create a variable with the scope set to this event handler. Set EvaluateAsExpression to true. Using an expression, you can set the value of this variable to System::TaskName, which will hold the name of the data flow.
Beware, the scope of this variable is the event handler, not the package.