Answer: It was because Arachne kept on bragging that she was the best weaver.
Explanation: Athena cursed Arachne into a spider because she kept bragging about how she can weave beautiful tapestries. So one day Athena disguised herself as an old woman and had a weaving competition. Arachne was being super rude to the old woman (aka Athena), and when so many people liked the old woman's better, Arachne was jealous and she ripped Athena's tapestry. Soon, Athena revealed herself and cursed Arachne to be a spider so she can weave webs/learn her lesson. This is where the word 'arachnid' came from.
Hope it helps.