Viruses mutate because of genome replication errors, various interactions with their hosts and because of environmental factors like the sun's harmful UV rays.