This can happen for a number of reasons, even if you have properly programmed your Key/Slot for HMACSHA1 Challenge Response.
It could mean a faulty YubiKey device but first you should check the following setting using the "Yubikey Manager" tool. There is a setting to enable/disable specific functions for USB or NFC.
OTP via NFC/USB should be enabled, so make sure to check this.