The document says it's deprecated:
(method) editor.ICodeEditor.deltaDecorations(oldDecorations: string[], newDecorations: monaco.editor.IModelDeltaDecoration[]): string[] All decorations added through this call will get the ownerId of this editor.
@deprecated
The signature '(oldDecorations: string[], newDecorations: IModelDeltaDecoration[]): string[]' of 'editor.deltaDecorations' is deprecated.
but the only example I found still uses it
The document doesn't say anything about what replaced it.