Thanks for reaching out to Q&A.
Azure Functions is sanboxed environment. Applications are highly restricted in terms of their access of the file system.
Please look into File system restrictions and considerations . I would highly recommend you to use a Blob storage account to read and write files using the blob storage bindings available in Azure Functions. You can also take a look at the python sample for reference
I hope this helps!
Please 'Accept as answer' and ‘Upvote’ if it helped so that it can help others in the community looking for help on similar topics.