This is only supported on a plugin-by-plugin basis, and depending on what the broker offers. Many brokers only provide spot trading.

The Kraken plugin supports margin trading, but only when using the SET_LEVERAGE brokerCommand. The crypto futures plugins also support margin since the products are futures.