When looking at the spec page for that PC, it indicates that the original OS was FreeDOS, so at some point it was converted to Windows. Next, the statement - "my system is working on UEFI now but with MBR the dvd worked fine" does that mean when FreeDOS was installed it worked? Having UEFI does not necessarily mean the MBR was changed. MBR refers to the disc formatting and it can still be MBR with UEFI . When the drives bigger than 2TB came out, MBR could not address the drives properly while using the storage space beyong the 2TB limit of MBR so the formatting was changed to GPT to allow the larger drive size to be recognized. Windows 10 can use either of those, but if the drive is smaller than 2TB, it is not needed to be GPT.
DVD drive not recognized - Windows 10 has some of those problems in the newer version, such as the 10.0.19043.1165.
See this and go thru the guide to see if any of those suggestions work to restore the DVD drive.
https://www.groovypost.com/howto/fix-dvd-cd-drive-not-working-missing-windows-10/
I'm not an HP employee.
Did this message answer your question? Please indicate below as an Accepted Solution!
Did you find this message useful? Click on the "Was this reply helpful" Yes button.