In Ace Ventura: Pet Detective, Ace figures out that Lois Einhorne is actually Ray Finkle. During the climax, Ace tells the cops, Einhorne tells them that he's lying. Now, she clearly wouldn't want them to know, but she could have just said he was wrong instead of lying. Even if he really was wrong, he wouldn't be lying if he honestly believed it.
And then he proves that she was a man and this is enough to prove she's Finkle. But just because she's proven to have had a sex change doesn't mean she was who they were after. We know that she was, but she could have kept it a secret just to keep it a secret as opposed to hiding the fact that she was a wanted criminal.