Normally these office 365 groups are created from Outlook, or from the admin portal of O365. Although, as of this post, there is no way to create a group for a secondary domain... at least with a graphical interface.
So if you have primarycompany.com and you also have secondarycompany.com registered with your office 365 tenant, how do you create these amazing groups for secondarycompany.com?
Powershell of course!
Start by opening up powershell with admin permissions. You will need your powershell to have your execution policy set to Remotesigned (or less secure).
Then you can use the below commands to connect to office 365's powershell session.
$user = get-credential
$Session = New-PSSession -ConfigurationName Microsoft.Exchange -ConnectionUri https://outlook.office365.com/powershell-liveid/ -Credential $user -Authentication Basic -AllowRedirection
Next setup your variables and create the group!
$displayName = "desired group display name"
$members = @('member1','member2')
$owner = "owner name"
$primarySmtp = "firstname.lastname@example.org"
$alias = "the alias you want"
$emailAddresses = @("email@example.com","firstname.lastname@example.org")
New-UnifiedGroup -DisplayName $displayName -Members $members -Owner $owner -PrimarySmtpAddress $primarySmtp -Alias 'Contact' -EmailAddresses $emailAddresses
That's it! You can add more options if you like or you can run the above and then manage the group from the admin portal.
One day Microsoft will enable domain select from their GUI... one day..