Dear @Moor,
Welcome to the Wefugees Community and thank you for your question.
Yes, you can study in a master's program - even if you are still in the asylum procedure. As far as I know, you won't need the permission of the immigration office (Ausländerbehörde). However, in practice people often experience difficulties, for instance in meeting the requirements of the respective universities or in the acknowledgement of their educational background. I would recommend you to contact a counselling office for individual support and advice. Please let us know if you need help in finding a respective office in your area. In any case, also don't hesitate to get back to us with any further questions.
All the best,
Meike