How to randomly place models within an area without them overlapping?

So I got lazy trying to do this manually so I decided to make some code to generate a bunch of models randomly within an area for me the issue is I don’t know what I should use to check if the model is overlapping something else.

Here is my code which currently just handles spawning the model within the area.

local function PlaceCube(innerCube,outerCube)
	task.wait(0.5)
	
	local randomCFrame = cubeSpawnArea.CFrame * CFrame.new(random:NextNumber(
		-cubeSpawnArea.Size.X/2,cubeSpawnArea.Size.X/2), 
		random:NextNumber(-cubeSpawnArea.Size.Y/2,cubeSpawnArea.Size.Y/2), 
		random:NextNumber(-cubeSpawnArea.Size.Z/2,cubeSpawnArea.Size.Z/2))
	
	--check if there's nothing in touching/at this position
	local tempValue = nil
	if tempValue then
		print("Retrying")
		PlaceCube(innerCube,outerCube)
	end
	
	return randomCFrame
end

for i = 0,cubesToSpawn,1 do
	local cubeClone = cubeModel:Clone()
	local innerCube = cubeClone.Inner
	local outerCube = cubeClone.Outer

	cubeClone.Parent = UIAssets
	innerCube.CFrame = PlaceCube(innerCube,outerCube)
	
	-- Spin the cube
	coroutine.wrap(function()
		while task.wait() do
			innerCube.CFrame *= CFrame.Angles(
				math.rad(speed),
				math.rad(speed),
				math.rad(speed)
			)	
		end	
	end)()
end