Summary of what I did
Edit: Works only if the disks have a GPT partition table.
MAKE SURE YOU ARE IN UEFI MODE IN BIOS FIRST
First I booted into live usb and created a 512mb partition with gparted on my drive, then I followed this guide
- Create the /boot/efi directory
sudo mkdir /boot/efi
3.) Mount the EFI partition as /boot/efi
sudo mount /dev/sdXY /boot/efi
X = Alphabet of the drive = a,b,c ... Y = Partition number of the EFI partition = 1,2,3,4...
Example - /dev/sda4
4.) Install Grub according to UEFI
sudo grub-install --target=x86_64-efi --efi-directory=/boot/efi --bootloader-id=manjaro --recheck
5.) Update Grub configuration file.
but before I ran commands 4 and 5 I ran sudo manjaro-chroot -a
Not sure if this is the correct way but it worked for me. My mistakes were not booting into live usb from UEFI and not running sudo manjaro-chroot -a after step 3