Hi, Janis.
There are few options. As Michael pointed out above, if the source of your users is some kind of external LDAP server, you could use Cache Refresh in Gluu to import the users, and custom scripts to transform their attributes any way you like.
As for your situation, if you have to add them via Import feature, you could try to write custom script of "Update user" type you can find on the similar named tab at "Configuration" > "Manage Custom scripts" page. Please note that writing custom scripts isn't covered by Community Support. It shouldn't be hard to figure it out though, if you are familiar with Java and Python.