The only IMAP mail service with a path prefix that I know works is Fastmail.fm. For some reason if you set the IMAP path prefix to INBOX and use port 992 (not 993), it syncs properly on Macs as well as iOS devices. But I have not been able to get HostGator's IMAP notes to work properly on my Mac. The notes sync just fine between my iPhone and iPad with HostGator, but do not sync with my Mac. Of course this creates the problem that a lot of people have reported - having lots of notes on their iOS devices that they can't move to iCloud to allow proper syncing without copying and pasting each note by hand, which is not very reasonable for anyone who already has a decent amount of notes.
So here is the way I managed to move all my Notes from HostGator to iCloud without copying and pasting them individually. I was able to use my Mail program and the webmail clients for Fastmail and Hostgator to copy the HostGator notes to my iCloud account by going through my Fastmail.fm Notes account which is sycning properly. This solution also takes advantage of the fact that the Notes folder on an IMAP email account is visible in webmail, even though it is hidden in Mac Mail.app.
1) In Webmail for the account that isn't syncing properly, create a new folder called Notes to Move, or whatever you want to call it.
2) Copy all the notes from the Notes folder into the new folder (Notes to Move, in my case). Now you should be able to see this folder, and all of your notes, in Mac Mail.app.
3) In Webmail or Mac Mail for the account that is syncing properly (Fastmail for me, or perhaps gmail in your case), create a new folder. Call it Notes from My Other Account, or whatever you like.
4) In Mac Mail.app you should be able to copy the notes (stored as messages really) from the Notes to Move folder into the Notes from My Other Account folder.
5) In webmail for the account that is syncing properly, copy the messages (i.e. the notes) from the Notes from My Other Account folder into the Notes folder that contains the notes that are syncing correctly between all of your devices. - If you want to keep these notes separate, you can first create a new folder in the Notes.app on your mac, or create a subfolder in the Notes folder using webmail.
6) Finally, you can now use Notes.app on your mac to copy the appropriate notes from the account that is syncing properly into the iCloud Notes folder.