There is more than one problem in that short bit of code.
First, the $group variable will hold an array with as many members as there are users (enabled and disabled) in the AD. I don't think that's what you want.
Second, the regex won't work if any of your distinguished names include an escaped comma (e.g., "\," in "CN=Surname\, GivenName,OU=...").
Third, the positive lookahead ("?=") in the regex is just looking for any two letters followed by an equal sign. It doesn't matter if they're "OU" or "abcdefgh".
If you just want to remove the CN from a distinguishedName, use this:
$regex = 'CN=.*?(?<!\\),(.*)'
$DnMinusTheCN = $obj.distinguishedname -replace $regex,'$1' # remove the CN from the DN