In XCOM 2, human soldiers can retrain their skills in the Advanced Warfare Centre. Is there anyway to retrain a SPARK?
According to this Reddit post, SPARKs can be retrained in the AWC just like any other soldier. Unless they are currently being repaired; which means they are considered not operational.
I can confirm this works; I've retrained my SPARK in the past.
However, it's possible that a mod you have installed is causing an issue here. It wouldn't be the first time something like this has happened.
I've never encountered the issue though. Although I've only retrained a SPARK once.