Disk image creation from folder: error 28 - no space left on device
Well...
It seems that APFS and/or iCloud Drive has killed the ability to create a disk image from an entire disk...
I tried lots of things, even Disk Utility's Restore in a freshly-created disk-image failed.

So I did it the hard way, with the terminal


Creation of a disk image (lot bigger than the drive) hdiutil create -size 500g -fs HFS+ -volname Clone\ Macintosh\ HD /Volumes/WD\ 1To/Clone\ MBA.dmg
Mounting the disk image
hdiutil attach /Volumes/WD\ 1To/Clone\ MBA.dmg
Note the /dev/disk_s_ path to unmount it
Save the disk with RSYNC (options and exclusions found on the internet)
sudo rsync -vaEx /Volumes/Macintosh\ HD/ /Volumes/Clone\ Macintosh\ HD --exclude=/Volumes/* --exclude=/Network/* --exclude=/automount/* --exclude=/dev/* --exclude=/private/tmp/* --exclude=/private/var/run/* --exclude=/private/var/spool/postfix/* --exclude=/private/var/vm/* --exclude=.Spotlight-*/ --exclude=.Trashes --exclude=*/.Trash --exclude=/afs/* --exclude=/cores/*
The result was bigger than the original drive (probably due to APFS which have some tricks to not duplicate data when copying a file, and certainly due to the saving of documents that are on iCloud Drive but not really on the disk: icons with a cloud badge) 
Detach the image hdiutil detach /dev/disk3s2
Then I tried to shrink the disk image from the command-line, but neither hdiutil compact, not hdiutil resize worked (errors)
Then I tried to resize with Disk Utility, but it didn't work too (disk utility claimed it was done, but the size didn't change at all)
So I converted the image to read-only with Disk Utility (in fact, it duplicated the image), and now I have a shrinked disk-image of my entire startup disk!


Lot of wasted time, it used to be easyer