Democracy is not only rule of majority. It is also protection of the constitution and minorities. The AfD clearly is against both and thus is not democratic and should be banned.
There is nothing intrinsic to democracy that means you need to have a constitution. This should be obvious since many democratic states and organizations have no constitution! The UK has no formal constitution, neither does Israel. Canada also has no single constitution document. There are probably lots of non-democracies out there that have constitutions. It's completely orthogonal to whether or not a place is a democracy.
But Germany has a constitution and it allows to ban parties, that act against it. Would you say, that makes Germany not democratic?