If the frame and engine "match" in size, ie: if there's enough room to cram the engine in, then yes it can be done. I've mated a pre-unit Triumph with a Commando box and mounted them in a featherbed frame, same with a BSA A50 in a featherbed, another BSA in a '70s chopper frame built for a Norton, and the toughest, a BSA unit construction engine in a rigid early '50s Triumph frame (moved the seat post back). Some thought, steel stock, a grinder and a welder, anything can be done. See if the existing engine mounts can be adapted using at least 1/4" 6061 T6 aluminum, if not cut out all engine mounts, set your engine in using blocks of wood, shims etc to get it dead square, then fabricate brackets to mount the engine. Keep in mind your chain line depending on what the frame was originally designed for and what wheel you're using. Theoretically it could be done in a weekend but don't rush it. Borrow or rent a wire feed welder and tack everything in place and haul it to a shop to be welded, preferably with the engine in place to reduce warping. Good luck. If you do go a head with it, post some pictures.
One more thought, keep in mind registering the bike. What #s if any are on the frame etc.