Can tanh be used as an output for a binary classifier?
If you label your data using -1 and 1 as classes, then yes you can. However, there are two reasons why data scientists normally prefer Sigmoid activations:


Loss functions, such as cross entropy based, are designed for data in the [0, 1] interval.
Better interpretability: data in [0, 1] can be thought as probabilities of belonging to acertain class, or as a model's confidence about it.


But yeah, you can use Tanh and train useful models with it.