First I installed windows 10 with bootcamp, just to exchange data between MacOs and windows I created a partition Ex-fat of 50GB, after sharing data I decided to remove an extra partition to merge its space to MacOs,(firstly I tried with disk utility but when I deleted it, it’s size become 272 GB but I only assigned it 50 GB, I erased it and selected apfs type, it was not merging, However I tried with terminal) after deletion with ‘diskutil’ commands, partition become free space and only show on command ‘diskutil list’ I want to restore free space and assign it to MacOs (this free space is not visible in disk utility and ‘diskutil apfs resizeContainer disk0s2 0’ – this command is not working but returning an error. ) enter image description here