Technically, it is possible and this documentation page shows how you could do that.
However, the Prefect context is not meant to be mutable so adding an item to it inside a task will not take effect in downstream tasks.
Recommended approach
The following Prefect features allow you to set and dynamically overwrite key-value pairs in your flow: