Add Folder to Sidebar - 2021

I updated a script that I originally found in this thread []. The only minimal gripe I have is that when the folder gets added to the sidebar, it always places it at the bottom of the list. Is it possible to script the placement of an item in the sidebar? Ideally I would like to have it placed at the top.


tell application "Finder"
	set theFolder to choose folder default location (path to desktop folder) as alias --choose the folder to put in the sidebar
	select theFolder
	tell application "System Events" to tell process "Finder" to keystroke "t" using {command down, control down} --puts folder in sidebar, at the bottom
end tell