I have Nextcloud 24 with several users. For some reason, whenever someone creates a subfolder under main folders I shared, I am the owner of this subfolder. Is there any way to have the person creating the subfolder be the owner?
No. If you shared the parent folder, then anything placed in it (including other folders) is part of your data.