Presumably you have updated your iPad to iPadOS 27.x.
iPadOS 27.x has introduced a bug that inhibits the lock-sound that is normally heard when (a) closing the iPad's screen cover - and (b) when manually locking the iPad with the physical sleep/wake button. If the iPad is restarted, the lock sound will be heard just once upon locking - after which the lock-sound is again silenced until such time as the iPad is next restarted. Tests indicate that while the lock-sound is silenced, the iPad does "lock" as expected.
You and anyone else that encounters this bug is strongly encouraged to submit a Bug Report to Apple via its Product Feedback portal. For iPad and iPadOS:
Feedback - iPad - Apple
When submitting a Bug Report, ensure that you include details of your iPad model and installed version of iPadOS within the body-text of your report. Don't rely upon the pick-list alone - as this rarely includes the current versions.
Please don't rely upon others alone to submit a Bug Report - as until Apple receive a sufficient number of reports, it may not assign resources to investigate and resolve the issue. Yours might be the report that triggers action.
You might also be well advised to seek assistance directly from Apple Support - as they may wish to record and escalate as appropriate. You can contact the Support Team using the Support link at top-right or bottom-left of this page. Alternatively you can initiate and manage your support cases from Apple devices using the excellent Apple Support App. If not already installed, the App can be downloaded from the App Store:
https://apps.apple.com/app/apple-support/id1130498044