Homebrew applies the com.apple.quarantine extended attribute to files a cask downloads, exactly as a browser would. macOS then evaluates the app on first launch, and an app that is unsigned or not notarized is refused with a message about the developer not being verified or the app being damaged.
Inspect the attribute with 'xattr -l /Applications/Example.app'. The presence of com.apple.quarantine confirms the cause.
Installing with 'brew install --cask --no-quarantine name' skips the attribute, and some casks set no_quarantine themselves. Do this only for software you actually trust, because the quarantine flag is what triggers notarization checking and malware scanning. Stripping it afterwards with 'xattr -dr com.apple.quarantine' has the same effect and the same caveat. On Apple Silicon there is a second, unrelated failure mode: an Intel-only application needs Rosetta, and without it the app fails to launch with a message about needing to be updated rather than anything about quarantine.