Creating Mailboxes in Sierra

This script works fine in Yosemite. It fails in Sierra:

-- Folder "2017 Orders" resides in the "On My Mac" folder

set NewProjectName to text returned of (display dialog "Enter Name Here" default answer "Enter Name")

tell application "Mail"
	
	set mboxName to "2017 Orders/" & NewProjectName
	
	make new mailbox with properties {name:mboxName}
	
end tell

After a few minutes of spinning rainbow, I’ll get this error:

error “Mail got an error: AppleEvent timed out.” number -1712

Any tips on how I can get this going again?

Model: Mac mini (Late 2014)
AppleScript: 2.5
Browser: Safari 10.1.2 (12603.3.8)
Operating System: Mac OS X (10.12.5)