You can, if you only plan to use it on the sub-domain only and not on the top-level domain (*).
Example 1: if you activate on sub.mydomain.com, it’ll not work on mydomain.com or www.mydomain.com.
Example 2: if you activate on mydomain.com, it’ll work on www.mydomain.com but not on sub.mydomain.com.
(*) The subdomain www. is treated differently from other sub-domains, and is regarded as the top-level single domain.