When setting a cookie in JavaScript, you can use the semicolon (;) character to separate the different attributes of that cookie. Each attribute, such as the key-value pairs, expires date, path, domain, and so on, are concatenated to the document.cookie property, and separated by semicolon.