Fragmentation only affect spinning disks. Due to the fact that fragmentation puts files all over the place so it wears down the drive head making it search for each individual piece of the file. This doesn't affect SSDs since all it is, is flash chips, no spinning head or mechanical parts to get worn down. Thus making "seek" time nonexistant.
(seek time refers to how long the drive has to look for the file, more specifically in our case, the fragmented file parts)
Plus defragging an SSD wears it down since it has to read/write every fragmented file thus shortening the lifespan of the flash chips. But with modern SSDs its not a HUGE deal if you accidentally defrag.