I am not sure if i understand it right,
1. You created a NFS Datastore and add that datastore to your ESXi Host.
2. Create a new VM on that datastore
3. Use that NFS Datastore on the VM to format it?
If that´s right, i do not recommend to use a Datastore for both, a ESXi Host and a VM.
It is possible, that you destroy your VM´s that are on that Datastore.
Create a new NFS Shared storage only for your VM. Without using it on an ESXi Host.
Frank