Metasploit doesn't actually have a CWE identifier. You'll have to use a URL reference instead.  Here's a list of all the supported reference identifiers:
https://github.com/rapid7/metasploit-framework/blob/master/lib/msf/core/module/reference.rb#L95