مُسْلِمُونَ is nominative with wāw, while مُسْلِمِينَ is accusative/genitive with yāʾ: this is the sound masculine plural.
By contrast, مَسَاجِدُ / مَسَاجِدَ shows vowel endings, with genitive fatḥa in the usual indefinite diptote context.
Different plural classes have different case-marking rules.