Can kamma and sankharas be considered as synonyms? And if not, which are the differences between both? Which is the relationship between them?
Sankhara is a very broad word with many meanings or contexts (see link). For example, 'sankhara' can mean 'condition thing' therefore a material thing such as a tree or rock can be a 'sankhara'.
In the context of 'sankhara' a mental processes, unusually, the Parivatta Sutta states the sankhara khandha (aggregate) is intention. Since AN 6.63 states: "kamma is intention", it may seem 'kamma is sankhara' but this is not really ideal because it creates confusion. This is because a Buddha or arahant still has a functioning & pure sankhara khandha (aggregate) despite a Buddha has eradicated kamma (in the ordinary sense of the word).
Therefore, it is best to not regard 'sankhara' & 'kamma' as synonyms.
As a mental process, sankhara is 'thought'. There can be pure & undefiled thoughts. However, kamma is generally always impure & defiled, including 'good' karma (refer to MN 117).
There is pure kamma (per AN 6.63) however this pure kamma is the kamma that ends kamma. Because this type of kamma destroys kamma, it is best to not call it 'kamma' since how can the ending of kamma be kamma?
They are not synonyms. Kamma is one entity of Sankharas Dhamma. We can be taught by the following Buddha saying.
Intention (cetana) I tell you, is kamma. Intending, one does kamma by way of body, speech, & intellect.
Cetana is one of the Nama Kaya and as well as Sankhara Dhamma. Collectively speaking, everything is Sankhara Dhamma except Nirvana. Only Nirvana is Asankhara Dhamma (it is not maintained, use no effort to persist, not needed continuous care to survive/last).