The m prefix sets the character that immediately follows it as the regex delimiter (i.e., the character that separates the pattern from the modifier flags).
For instance, if your pattern contains a lot of / characters, and you don't want to escape them every time, you could use the m prefix to set the delimiter to, say, ~
//noop $regex(https://forums.mirc.com/ubbthreads.php,m~https?://([^/]+)/([^/]+))~gi) | echo -ga $regml(1) - $regml(2)
The reason your first example didn't work is because without the default // delimiters, m was seen as a delimiter setter that made "y" the delimiter, and so the actual pattern being matched was "fixed". In example three, because you used the // delimiters, the m was just seen as a literal m.