Its not that they don't work, the battle system is different here
Weakness/resistance/immunity is based on the type of the pokes, not the type of the moves used.
Also, its Type 1 vs Type 1 and Type 2 vs Type 2
Example:
Klefki is Steel/Fairy, Immune to Noivern because its Flying/Dragon, Type 2 Fairy are immune to Type 2 Dragons
Klefki dies to Rayquaza because ray is Dragon first, steel not immune to dragon.
Gengar can poison a klefki with Toxic, Alolan Muk cannot